166 lines
2.8 KiB
YAML
166 lines
2.8 KiB
YAML
kind: pipeline
|
|
type: docker
|
|
name: publish-amd64
|
|
|
|
platform:
|
|
arch: amd64
|
|
|
|
clone:
|
|
disable: true
|
|
|
|
steps:
|
|
- name: clone
|
|
image: alpine/git:latest
|
|
user: root
|
|
commands:
|
|
- git clone 'https://gitlab.com/famedly/conduit.git' .
|
|
- git checkout next
|
|
- git clone $DRONE_GIT_HTTP_URL meta/
|
|
- cd meta
|
|
- git checkout $DRONE_COMMIT
|
|
- cd ..
|
|
- rm rust-toolchain
|
|
- chown -R 991:991 .
|
|
|
|
- name: build
|
|
image: asonix/rust-builder:amd64-latest
|
|
pull: always
|
|
commands:
|
|
- cargo build --target=$TARGET --release
|
|
- $TOOL-strip target/$TARGET/release/conduit
|
|
- cp target/$TARGET/release/conduit .
|
|
- cp conduit conduit-linux-amd64
|
|
|
|
- name: push
|
|
image: plugins/docker:20
|
|
settings:
|
|
username: asonix
|
|
password:
|
|
from_secret: dockerhub_token
|
|
repo: asonix/conduit
|
|
dockerfile: meta/Dockerfile
|
|
auto_tag: true
|
|
auto_tag_suffix: linux-amd64
|
|
tags:
|
|
- latest-linux-arm64v8
|
|
build_args:
|
|
- REPO_ARCH=amd64
|
|
|
|
- name: publish
|
|
image: plugins/gitea-release:1
|
|
settings:
|
|
api_key:
|
|
from_secret: gitea_token
|
|
base_url: https://git.asonix.dog
|
|
files:
|
|
- conduit-linux-amd64
|
|
|
|
trigger:
|
|
event:
|
|
- tag
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
type: docker
|
|
name: publish-arm64v8
|
|
|
|
platform:
|
|
arch: amd64
|
|
|
|
clone:
|
|
disable: true
|
|
|
|
steps:
|
|
- name: clone
|
|
image: alpine/git:latest
|
|
user: root
|
|
commands:
|
|
- git clone 'https://gitlab.com/famedly/conduit.git' .
|
|
- git checkout next
|
|
- git clone $DRONE_GIT_HTTP_URL meta/
|
|
- cd meta
|
|
- git checkout $DRONE_COMMIT
|
|
- cd ..
|
|
- rm rust-toolchain
|
|
- chown -R 991:991 .
|
|
|
|
- name: build
|
|
image: asonix/rust-builder:arm64v8-latest
|
|
pull: always
|
|
commands:
|
|
- cargo build --target=$TARGET --release
|
|
- $TOOL-strip target/$TARGET/release/conduit
|
|
- cp target/$TARGET/release/conduit .
|
|
- cp conduit conduit-linux-arm64v8
|
|
|
|
- name: push
|
|
image: plugins/docker:20
|
|
settings:
|
|
username: asonix
|
|
password:
|
|
from_secret: dockerhub_token
|
|
repo: asonix/conduit
|
|
dockerfile: meta/Dockerfile
|
|
auto_tag: true
|
|
auto_tag_suffix: linux-arm64v8
|
|
tags:
|
|
- latest-linux-arm64v8
|
|
build_args:
|
|
- REPO_ARCH=arm64v8
|
|
|
|
- name: publish
|
|
image: plugins/gitea-release:1
|
|
settings:
|
|
api_key:
|
|
from_secret: gitea_token
|
|
base_url: https://git.asonix.dog
|
|
files:
|
|
- conduit-linux-arm64v8
|
|
|
|
trigger:
|
|
event:
|
|
- tag
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
type: docker
|
|
name: manifest
|
|
|
|
platform:
|
|
arch: amd64
|
|
|
|
clone:
|
|
disable: true
|
|
|
|
steps:
|
|
- name: clone
|
|
image: alpine/git:latest
|
|
user: root
|
|
commands:
|
|
- git clone $DRONE_GIT_HTTP_URL .
|
|
- git checkout $DRONE_COMMIT
|
|
- chown -R 991:991 .
|
|
|
|
- name: manifest
|
|
image: plugins/manifest:1
|
|
settings:
|
|
username: asonix
|
|
password:
|
|
from_secret: dockerhub_token
|
|
dump: true
|
|
auto_tag: true
|
|
tags:
|
|
- latest
|
|
ignore_missing: true
|
|
spec: manifest.tmpl
|
|
|
|
|
|
depends_on:
|
|
- publish-amd64
|
|
- publish-arm64v8
|
|
|
|
trigger:
|
|
event:
|
|
- tag
|