Commit 9ced573a authored by Derek Su's avatar Derek Su
Browse files

drone: build master-head image automatically



- "Push the master branch" triggers the image build process.
- "Tag" triggers the binary and image build process for stable release.

Signed-off-by: default avatarDerek Su <derek.su@suse.com>
parent 659e72d7
......@@ -31,9 +31,6 @@ steps:
when:
instance:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- tag
......@@ -44,7 +41,7 @@ steps:
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-amd64"
tag: "${DRONE_BRANCH}-head-amd64"
username:
from_secret: docker_username
when:
......@@ -52,7 +49,22 @@ steps:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- push
- name: docker-tagged-publish
image: plugins/docker
settings:
dockerfile: package/Dockerfile
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-amd64"
username:
from_secret: docker_username
when:
instance:
- drone-publish.rancher.io
event:
- tag
......@@ -94,9 +106,6 @@ steps:
when:
instance:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- tag
......@@ -107,7 +116,7 @@ steps:
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-arm64"
tag: "${DRONE_BRANCH}-head-arm64"
username:
from_secret: docker_username
when:
......@@ -115,7 +124,22 @@ steps:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- push
- name: docker-tagged-publish
image: plugins/docker
settings:
dockerfile: package/Dockerfile
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-arm64"
username:
from_secret: docker_username
when:
instance:
- drone-publish.rancher.io
event:
- tag
......@@ -156,9 +180,6 @@ steps:
when:
instance:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- tag
......@@ -169,7 +190,7 @@ steps:
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-arm"
tag: "${DRONE_BRANCH}-head-arm"
username:
from_secret: docker_username
when:
......@@ -177,7 +198,22 @@ steps:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- push
- name: docker-tagged-publish
image: plugins/docker
settings:
dockerfile: package/Dockerfile
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-arm"
username:
from_secret: docker_username
when:
instance:
- drone-publish.rancher.io
event:
- tag
......@@ -222,9 +258,6 @@ steps:
when:
instance:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- tag
......@@ -238,7 +271,7 @@ steps:
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-s390x"
tag: "${DRONE_BRANCH}-head-s390x"
username:
from_secret: docker_username
when:
......@@ -246,7 +279,25 @@ steps:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- push
- name: docker-tagged-publish
image: rancher/drone-images:docker-s390x
volumes:
- name: docker
path: /var/run/docker.sock
settings:
dockerfile: package/Dockerfile
password:
from_secret: docker_password
repo: "rancher/local-path-provisioner"
tag: "${DRONE_TAG}-s390x"
username:
from_secret: docker_username
when:
instance:
- drone-publish.rancher.io
event:
- tag
......@@ -276,14 +327,33 @@ steps:
- linux/arm64
- linux/arm
- linux/s390x
target: "rancher/local-path-provisioner:${DRONE_TAG}"
template: "rancher/local-path-provisioner:${DRONE_TAG}-ARCH"
target: "rancher/local-path-provisioner:${DRONE_BRANCH}-head"
template: "rancher/local-path-provisioner:${DRONE_BRANCH}-head-ARCH"
when:
instance:
- drone-publish.rancher.io
ref:
- refs/head/master
- refs/tags/*
event:
- push
- name: manifest-tag
image: plugins/manifest:1.0.2
settings:
username:
from_secret: docker_username
password:
from_secret: docker_password
platforms:
- linux/amd64
- linux/arm64
- linux/arm
- linux/s390x
target: "rancher/local-path-provisioner:${DRONE_TAG}"
template: "rancher/local-path-provisioner:${DRONE_TAG}-ARCH"
when:
instance:
- drone-publish.rancher.io
event:
- tag
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment