[DRONE] Rewrite build and publish CI
Some checks reported errors
continuous-integration/drone/push Build encountered an error
Some checks reported errors
continuous-integration/drone/push Build encountered an error
This commit is contained in:
parent
c7392f6b65
commit
27cb201d74
36
.drone.yml
36
.drone.yml
@ -5,24 +5,24 @@ type: 'kubernetes'
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
# build and publish
|
# build and publish
|
||||||
- name: 'publish'
|
- name: 'publish'
|
||||||
image: 'docker.io/library/docker'
|
image: 'docker.io/library/docker'
|
||||||
pull: 'always'
|
pull: 'always'
|
||||||
privileged: true
|
privileged: true
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
IMG: 'rakepanorama/ansible-deployment-container'
|
IMG: 'rakepanorama/ansible-deployment-container'
|
||||||
DOCKER_USER:
|
DOCKER_USER:
|
||||||
from_secret: 'docker_username'
|
from_secret: 'docker_username'
|
||||||
DOCKER_PASS:
|
DOCKER_PASS:
|
||||||
from_secret: 'docker_password'
|
from_secret: 'docker_password'
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
|
||||||
commands:
|
commands:
|
||||||
- 'echo building image ${IMG}'
|
- 'echo building image ${IMG}'
|
||||||
- 'docker login -u ${DOCKER_USER} -p ${DOCKER_PASS} docker.io'
|
- 'docker login -u ${DOCKER_USER} -p ${DOCKER_PASS} docker.io'
|
||||||
- 'docker build -t ${IMG}:v0.9 -t ${IMG}:latest -f Dockerfile.linux.amd64 .'
|
- 'docker build -t ${IMG}:v0.9 -t ${IMG}:latest -f Dockerfile.linux.amd64 .'
|
||||||
- 'docker push -a'
|
- 'docker push -a'
|
||||||
|
Loading…
Reference in New Issue
Block a user