Create commit based docker image.

This commit is contained in:
Naoki Kosaka 2019-07-28 19:47:59 +09:00
parent 17394e7e40
commit 8084db6403

View File

@ -24,11 +24,13 @@ jobs:
name: build docker image name: build docker image
command: | command: |
docker build -t ${DOCKER_USER}/activity-relay:edge . docker build -t ${DOCKER_USER}/activity-relay:edge .
docker tag ${DOCKER_USER}/activity-relay:edge ${DOCKER_USER}/activity-relay:$(echo ${CIRCLE_SHA1}|head -c7)
- run: - run:
name: upload image to docker hub. name: upload image to docker hub.
command: | command: |
docker login --username=${DOCKER_USER} --password=${DOCKER_PASS} docker login --username=${DOCKER_USER} --password=${DOCKER_PASS}
docker push ${DOCKER_USER}/activity-relay:edge docker push ${DOCKER_USER}/activity-relay:edge
docker push ${DOCKER_USER}/activity-relay:$(echo ${CIRCLE_SHA1}|head -c7)
workflows: workflows:
version: 2 version: 2