[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
560ca45bd1
commit
6287a40649
36
.drone.yml
36
.drone.yml
@ -6,30 +6,22 @@ type: 'kubernetes'
|
|||||||
steps:
|
steps:
|
||||||
|
|
||||||
# build and publish
|
# build and publish
|
||||||
- image: 'plugins/docker'
|
- name: 'publish'
|
||||||
name: 'publish'
|
image: 'docker.io/library/docker'
|
||||||
pull: 'always'
|
pull: 'always'
|
||||||
settings:
|
|
||||||
|
|
||||||
# registery and repos
|
environment:
|
||||||
registry: 'docker.io'
|
IMG: 'rakepanorama/ansible-deployment-container'
|
||||||
cache_from: 'rakepanorama/ansible-deployment'
|
DOCKER_USER:
|
||||||
repo: 'rakepanorama/ansible-deployment'
|
|
||||||
custom_dns: '8.8.8.8'
|
|
||||||
build_args: '--network host'
|
|
||||||
debug: true
|
|
||||||
|
|
||||||
# build stuff
|
|
||||||
dockerfile: 'Dockerfile.linux.amd64'
|
|
||||||
daemon_off: 'false'
|
|
||||||
|
|
||||||
# authentication
|
|
||||||
username:
|
|
||||||
from_secret: 'docker_username'
|
from_secret: 'docker_username'
|
||||||
password:
|
DOCKER_PASS:
|
||||||
from_secret: 'docker_password'
|
from_secret: 'docker_password'
|
||||||
|
|
||||||
# tags
|
volumes:
|
||||||
tags:
|
- '/var/run/docker.sock:/var/run/docker.sock'
|
||||||
- 'v0.9'
|
|
||||||
- 'latest'
|
commands:
|
||||||
|
- 'echo building image ${IMG}'
|
||||||
|
- 'docker login -u ${DOCKER_USER} -p ${DOCKER_PASS} docker.io'
|
||||||
|
- 'docker build -t ${IMG}:v0.9 -t ${IMG}:latest -f Dockerfile.linux.amd64 .'
|
||||||
|
- 'docker push -a'
|
||||||
|
Loading…
Reference in New Issue
Block a user