Add TLS enabled comms to the swarm
This commit is contained in:
parent
166cf8cd4c
commit
8bd55ac322
16
Makefile
16
Makefile
@ -1,6 +1,8 @@
|
||||
STACK := traefik
|
||||
COMPOSE_FILE := docker-compose.yml
|
||||
CONFIG := $$HOME/.docker
|
||||
NETWORK := proxy
|
||||
STACK := traefik
|
||||
SWARM_URL := tcp://swarm.autonomic.zone:2376
|
||||
|
||||
default: deploy
|
||||
|
||||
@ -16,4 +18,14 @@ network:
|
||||
logs:
|
||||
@docker service logs -f $(STACK)_$(STACK)
|
||||
|
||||
.PHONY: deploy
|
||||
config:
|
||||
mkdir -vp $(CONFIG) && \
|
||||
pass show docker/swarm.autonomic.zone/ca.pem > $(CONFIG)/ca.pem && \
|
||||
pass show docker/swarm.autonomic.zone/cert.pem > $(CONFIG)/cert.pem && \
|
||||
pass show docker/swarm.autonomic.zone/key.pem > $(CONFIG)/key.pem
|
||||
|
||||
context:
|
||||
@docker context create swarm.autonomic.zone --docker \
|
||||
"host=$(SWARM_URL),ca=$(CONFIG)/ca.pem,cert=$(CONFIG)/cert.pem,key=$(CONFIG)/key.pem"
|
||||
|
||||
.PHONY: deploy down network logs context
|
||||
|
Reference in New Issue
Block a user