Try to slim down config
This commit is contained in:
parent
633d61e946
commit
efff580100
@ -3,11 +3,10 @@ kind: pipeline
|
||||
name: deploy to swarm.autonomic.zone
|
||||
steps:
|
||||
- name: deployment
|
||||
image: decentral1se/drone-stack:19.03.8-override-compose
|
||||
image: decentral1se/drone-stack:19.03.8
|
||||
settings:
|
||||
compose: docker-compose.yml
|
||||
compose: docker-compose.prod.yml
|
||||
host: tcp://swarm.autonomic.zone:2376
|
||||
override_compose: docker-compose.production.yml
|
||||
stack_name: traefik
|
||||
tlsverify: true
|
||||
environment:
|
||||
|
30
README.md
30
README.md
@ -3,33 +3,3 @@
|
||||
[](https://drone.autonomic.zone/autonomic-cooperative/traefik)
|
||||
|
||||
> https://docs.traefik.io/
|
||||
|
||||
> https://traefik.swarm.autonomic.zone
|
||||
|
||||
## Development
|
||||
|
||||
```bash
|
||||
$ git clone https://git.autonomic.zone/autonomic-cooperative/traefik && cd traefik
|
||||
$ python3 -m venv .venv && source .venv/bin/activate
|
||||
$ pip install -r requirements.txt
|
||||
$ docker-compose up
|
||||
```
|
||||
|
||||
Traefik dashboard:
|
||||
|
||||
> http://traefik.localhost
|
||||
|
||||
Test application:
|
||||
|
||||
> http://whoami.localhost
|
||||
|
||||
Also available via (testing routing of proxy):
|
||||
|
||||
```bash
|
||||
$ curl -H Host:whoami.localhost http://127.0.0.1
|
||||
```
|
||||
|
||||
## Production
|
||||
|
||||
1. Our [drone.autonomic.zone](https://drone.autonomic.zone/autonomic-cooperative/traefik/) configuration automatically deploys.
|
||||
1. For a manual deploy guide, see [this documentation](https://git.autonomic.zone/autonomic-cooperative/organising/wiki/working-with-docker-swarm).
|
||||
|
@ -3,26 +3,24 @@ version: "3.8"
|
||||
|
||||
services:
|
||||
traefik:
|
||||
container_name: traefik
|
||||
image: "traefik:v2.2"
|
||||
ports:
|
||||
- "80:80"
|
||||
- "8080:8080"
|
||||
volumes:
|
||||
- "/var/run/docker.sock:/var/run/docker.sock"
|
||||
- "letsencrypt:/etc/letsencrypt"
|
||||
command:
|
||||
- "--api=true"
|
||||
- "--api.insecure=true"
|
||||
- "--providers.docker=true"
|
||||
- "--providers.docker.exposedbydefault=false"
|
||||
- "--entrypoints.web.address=:80"
|
||||
volumes:
|
||||
- "/var/run/docker.sock:/var/run/docker.sock"
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.traefik.rule=Host(`traefik.localhost`)"
|
||||
- "traefik.http.routers.traefik.entrypoints=web"
|
||||
- "traefik.http.routers.traefik.service=api@internal"
|
||||
|
||||
whoami:
|
||||
image: containous/whoami
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
- "traefik.http.routers.whoami.rule=Host(`whoami.localhost`)"
|
||||
volumes:
|
||||
letsencrypt:
|
@ -3,6 +3,7 @@ version: "3.8"
|
||||
|
||||
services:
|
||||
traefik:
|
||||
image: "traefik:v2.2"
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
@ -1,6 +0,0 @@
|
||||
---
|
||||
version: "3.8"
|
||||
|
||||
services:
|
||||
traefik:
|
||||
image: "traefik:v2.2"
|
Reference in New Issue
Block a user