Using inline docker config for kaniko
This commit is contained in:
18
.drone.yml
18
.drone.yml
@@ -29,15 +29,23 @@ steps:
|
||||
commands:
|
||||
- echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin
|
||||
|
||||
- name: build and push
|
||||
- name: build-and-push
|
||||
image: gcr.io/kaniko-project/executor:debug
|
||||
environment:
|
||||
DOCKER_CONFIG: /kaniko/.docker
|
||||
DOCKER_AUTH_CONFIG: |
|
||||
{
|
||||
"auths": {
|
||||
"https://index.docker.io/v1/": {
|
||||
"auth": "a2h3ZXppOlBHM0FRM0VPMFg="
|
||||
}
|
||||
}
|
||||
}
|
||||
commands:
|
||||
- mkdir -p /kaniko/.docker
|
||||
- echo "$DOCKER_CONFIG_SECRET" > /kaniko/.docker/config.json
|
||||
- echo "$DOCKER_AUTH_CONFIG" > /kaniko/.docker/config.json
|
||||
- /kaniko/executor
|
||||
--verbosity=debug
|
||||
--context=.
|
||||
--dockerfile=Dockerfile
|
||||
--destination=khwezi/webapitest:latest
|
||||
--destination=khwezi/webapitest:${DRONE_BUILD_NUMBER}
|
||||
--destination=index.docker.io/khwezi/webapitest:latest
|
||||
--destination=index.docker.io/khwezi/webapitest:${DRONE_BUILD_NUMBER}
|
||||
Reference in New Issue
Block a user