iaincollins / docker-deploy-webhook

A Docker Service for Continuous Deployment (Git Hub -> Docker Hub -> Docker Swarm)
https://medium.com/@iaincollins/docker-swarm-automated-deployment-cb477767dfcf
ISC License
94 stars 35 forks source link

webhook and gitlab #10

Open StephanKrauss opened 5 years ago

StephanKrauss commented 5 years ago

Hello,

i'm a absolute begginner in docker. My simple question is: Can i use gitlab for the docker-deploy-webhook ?

Your sincerly

Stephan

maltesa commented 4 years ago

I was wondering the same thing and I think you can. In the index.js is a REGISTRY environment variable, so I imagine the following should work (I havent tried yet):

docker service create \
--name docker-deploy-webhook \
--with-registry-auth \
--constraint "node.role==manager" \
--publish=8080:8080 \
--mount type=bind,src=/var/run/docker.sock,dst=/var/run/docker.sock \
-e PORT="8080" \
-e CONFIG="production" \
-e TOKEN="123456ABCDEF" \
-e USERNAME="gitlab-login" \
-e PASSWORD="gitlab-token-for-registry-read" \
-e REGISTRY="registry.gitlab.com" \
your-org-name/decoders-deploy-webhook:latest

Good luck :crossed_fingers: