2020-10-08 20:06:36 +00:00
|
|
|
---
|
|
|
|
name: jfa-go
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: fetch
|
|
|
|
image: docker:git
|
|
|
|
commands:
|
|
|
|
- git fetch --tags
|
|
|
|
- name: release
|
|
|
|
image: golang:latest
|
|
|
|
environment:
|
|
|
|
GITHUB_TOKEN:
|
|
|
|
from_secret: github_token
|
|
|
|
commands:
|
|
|
|
- apt update -y
|
|
|
|
- apt install build-essential python3-pip curl software-properties-common sed upx -y
|
|
|
|
- (curl -sL https://deb.nodesource.com/setup_14.x | bash -)
|
|
|
|
- apt install nodejs
|
|
|
|
- curl -sL https://git.io/goreleaser | bash
|
2021-02-11 22:25:00 +00:00
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- tag
|
2021-02-11 16:24:32 +00:00
|
|
|
---
|
2021-02-11 21:18:32 +00:00
|
|
|
name: amd64-docker
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
steps:
|
|
|
|
- name: fetch
|
|
|
|
image: docker:git
|
|
|
|
commands:
|
|
|
|
- git fetch --tags
|
|
|
|
- name: build
|
|
|
|
image: plugins/docker
|
|
|
|
settings:
|
|
|
|
username: hrfee
|
|
|
|
password:
|
|
|
|
from_secret: docker_key
|
|
|
|
repo: hrfee/jfa-go
|
|
|
|
tags: manifest-latest-amd64
|
2021-02-11 22:25:00 +00:00
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- tag
|
2021-02-11 21:18:32 +00:00
|
|
|
---
|
2021-02-11 22:25:00 +00:00
|
|
|
name: arm64-docker
|
2021-02-11 16:24:32 +00:00
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
2020-10-08 20:06:36 +00:00
|
|
|
|
2021-02-11 16:24:32 +00:00
|
|
|
steps:
|
2021-02-11 22:25:00 +00:00
|
|
|
- name: arm64-ssh
|
2021-02-11 16:24:32 +00:00
|
|
|
image: appleboy/drone-ssh
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
|
|
|
settings:
|
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
|
|
|
volumes:
|
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 16:24:32 +00:00
|
|
|
script:
|
|
|
|
- /home/rock64/jfa-go-build/build-stable.sh
|
2021-02-11 22:25:00 +00:00
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- tag
|
2021-02-11 16:24:32 +00:00
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
|
|
|
---
|
|
|
|
name: armhf-docker
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: armhf-ssh
|
|
|
|
image: appleboy/drone-ssh
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
|
|
|
settings:
|
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
|
|
|
volumes:
|
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 16:24:32 +00:00
|
|
|
script:
|
|
|
|
- ssh pi /home/pi/jfa-go-build/build-stable.sh
|
2021-02-11 22:25:00 +00:00
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- tag
|
2021-02-11 16:24:32 +00:00
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
2020-09-29 22:28:14 +00:00
|
|
|
---
|
2021-02-11 21:18:32 +00:00
|
|
|
name: docker-manifest
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: manifest
|
2021-02-11 23:52:05 +00:00
|
|
|
image: appleboy/drone-ssh
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
2021-02-11 21:18:32 +00:00
|
|
|
settings:
|
2021-02-11 23:52:05 +00:00
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
|
|
|
volumes:
|
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 23:52:05 +00:00
|
|
|
script:
|
|
|
|
- env DOCKER_CLI_EXPERIMENTAL=enabled docker manifest create hrfee/jfa-go:latest --amend hrfee/jfa-go:manifest-latest-amd64 --amend hrfee/jfa-go:manifest-latest-arm64 --amend hrfee/jfa-go:manifest-latest-armhf
|
|
|
|
- env DOCKER_CLI_EXPERIMENTAL=enabled docker manifest push hrfee/jfa-go:latest
|
2021-02-11 22:25:00 +00:00
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
- tag
|
2021-02-11 23:52:05 +00:00
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
2021-02-11 21:18:32 +00:00
|
|
|
depends_on:
|
|
|
|
- amd64-docker
|
2021-02-11 22:25:00 +00:00
|
|
|
- arm64-docker
|
2021-02-11 21:18:32 +00:00
|
|
|
- armhf-docker
|
|
|
|
---
|
2021-02-01 20:25:20 +00:00
|
|
|
name: jfa-go-1.16-git
|
2020-09-29 22:28:14 +00:00
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: build
|
2021-02-01 20:25:20 +00:00
|
|
|
image: golang:1.16rc
|
2020-09-29 22:28:14 +00:00
|
|
|
commands:
|
|
|
|
- apt update -y
|
|
|
|
- apt install build-essential python3-pip curl software-properties-common sed upx -y
|
|
|
|
- (curl -sL https://deb.nodesource.com/setup_14.x | bash -)
|
|
|
|
- apt install nodejs
|
2020-10-08 20:06:36 +00:00
|
|
|
- curl -sL https://git.io/goreleaser > goreleaser.sh
|
|
|
|
- chmod +x goreleaser.sh
|
|
|
|
- ./goreleaser.sh --snapshot --skip-publish --rm-dist
|
|
|
|
- wget https://builds.hrfee.pw/upload.py
|
2020-10-08 20:48:15 +00:00
|
|
|
- pip3 install requests
|
2020-10-08 20:37:44 +00:00
|
|
|
- bash -c 'python3 upload.py https://builds.hrfee.pw hrfee jfa-go ./dist/*.tar.gz'
|
2020-10-08 20:10:31 +00:00
|
|
|
environment:
|
|
|
|
BUILDRONE_KEY:
|
|
|
|
from_secret: BUILDRONE_KEY
|
2021-02-11 16:11:07 +00:00
|
|
|
|
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- main
|
|
|
|
- go1.16
|
|
|
|
event:
|
|
|
|
exclude:
|
|
|
|
- pull_request
|
|
|
|
|
|
|
|
---
|
2021-02-11 21:18:32 +00:00
|
|
|
name: amd64-docker-git
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
steps:
|
|
|
|
- name: build
|
|
|
|
image: plugins/docker
|
|
|
|
settings:
|
|
|
|
username: hrfee
|
|
|
|
password:
|
|
|
|
from_secret: docker_key
|
|
|
|
repo: hrfee/jfa-go
|
|
|
|
tags: manifest-unstable-amd64
|
|
|
|
|
|
|
|
---
|
2021-02-11 22:25:00 +00:00
|
|
|
name: arm64-docker-git
|
2021-02-11 16:11:07 +00:00
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
2021-02-11 22:25:00 +00:00
|
|
|
- name: arm64-ssh
|
2021-02-11 15:29:33 +00:00
|
|
|
image: appleboy/drone-ssh
|
2021-02-11 15:48:13 +00:00
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
2021-02-11 15:29:33 +00:00
|
|
|
settings:
|
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
2021-02-11 15:37:02 +00:00
|
|
|
volumes:
|
2021-02-11 15:48:13 +00:00
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 15:29:33 +00:00
|
|
|
script:
|
|
|
|
- /home/rock64/jfa-go-build/build.sh
|
2021-02-11 16:24:32 +00:00
|
|
|
|
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- main
|
|
|
|
- go1.16
|
|
|
|
event:
|
|
|
|
exclude:
|
|
|
|
- pull_request
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
|
|
|
---
|
|
|
|
name: armhf-docker-git
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
2021-02-11 16:11:07 +00:00
|
|
|
- name: armhf-ssh
|
|
|
|
image: appleboy/drone-ssh
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
|
|
|
settings:
|
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
|
|
|
volumes:
|
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 16:11:07 +00:00
|
|
|
script:
|
|
|
|
- ssh pi /home/pi/jfa-go-build/build.sh
|
2021-02-11 15:48:13 +00:00
|
|
|
|
2021-01-08 23:52:36 +00:00
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- main
|
2021-02-01 18:43:30 +00:00
|
|
|
- go1.16
|
2021-01-08 23:52:36 +00:00
|
|
|
event:
|
|
|
|
exclude:
|
|
|
|
- pull_request
|
|
|
|
|
2021-02-11 16:11:07 +00:00
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
2021-02-11 16:14:39 +00:00
|
|
|
---
|
2021-02-11 21:18:32 +00:00
|
|
|
name: docker-manifest-unstable
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: manifest
|
2021-02-11 23:52:05 +00:00
|
|
|
image: appleboy/drone-ssh
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
path: /root/drone_rsa
|
2021-02-11 21:18:32 +00:00
|
|
|
settings:
|
2021-02-11 23:52:05 +00:00
|
|
|
host:
|
|
|
|
from_secret: ssh_host
|
|
|
|
username:
|
|
|
|
from_secret: ssh_username
|
|
|
|
port:
|
|
|
|
from_secret: ssh_port
|
|
|
|
volumes:
|
|
|
|
- /root/.ssh/docker-build:/root/drone_rsa
|
|
|
|
key_path: /root/drone_rsa
|
2021-02-12 13:38:34 +00:00
|
|
|
command_timeout: 50m
|
2021-02-11 23:52:05 +00:00
|
|
|
script:
|
|
|
|
- env DOCKER_CLI_EXPERIMENTAL=enabled docker manifest create hrfee/jfa-go:unstable --amend hrfee/jfa-go:manifest-unstable-amd64 --amend hrfee/jfa-go:manifest-unstable-arm64 --amend hrfee/jfa-go:manifest-unstable-armhf
|
|
|
|
- env DOCKER_CLI_EXPERIMENTAL=enabled docker manifest push hrfee/jfa-go:unstable
|
2021-02-11 21:18:32 +00:00
|
|
|
depends_on:
|
|
|
|
- amd64-docker-git
|
2021-02-11 22:25:00 +00:00
|
|
|
- arm64-docker-git
|
2021-02-11 21:18:32 +00:00
|
|
|
- armhf-docker-git
|
2021-02-12 00:35:20 +00:00
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- main
|
|
|
|
- go1.16
|
|
|
|
event:
|
|
|
|
exclude:
|
|
|
|
- pull_request
|
|
|
|
|
|
|
|
volumes:
|
|
|
|
- name: ssh_key
|
|
|
|
host:
|
|
|
|
path: /root/.ssh/docker-build
|
2021-02-11 21:18:32 +00:00
|
|
|
---
|
2021-01-08 23:52:36 +00:00
|
|
|
name: jfa-go-pr
|
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: build
|
|
|
|
image: golang:latest
|
|
|
|
commands:
|
|
|
|
- apt update -y
|
|
|
|
- apt install build-essential python3-pip curl software-properties-common sed upx -y
|
|
|
|
- (curl -sL https://deb.nodesource.com/setup_14.x | bash -)
|
|
|
|
- apt install nodejs
|
|
|
|
- curl -sL https://git.io/goreleaser > goreleaser.sh
|
|
|
|
- chmod +x goreleaser.sh
|
|
|
|
- ./goreleaser.sh --snapshot --skip-publish --rm-dist
|
|
|
|
|
|
|
|
trigger:
|
|
|
|
event:
|
|
|
|
include:
|
|
|
|
- pull_request
|
2021-02-11 15:29:33 +00:00
|
|
|
|