Skip to content

Commit

Permalink
Added traefik dashboard url
Browse files Browse the repository at this point in the history
  • Loading branch information
edyan committed May 21, 2021
1 parent 7b023a4 commit d03c775
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions stakkr/proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ def __init__(self,
def start(self, stakkr_network: str = None):
"""Start stakkr proxy if stopped."""
if docker.container_running(self.ct_name) is False:
print(click.style('[STARTING]', fg='green') + ' traefik')
msg = ' traefik (Dashboard: http://traefik.docker.localhost)'
print(click.style('[STARTING]', fg='green') + msg)
self._start_container()

# Connect it to network if asked
Expand Down Expand Up @@ -54,6 +55,7 @@ def _start_container(self):
'{}/config.yml:/etc/traefik/config.yml'.format(proxy_conf_dir),
'{}/ssl:/etc/traefik/ssl'.format(proxy_conf_dir)],
labels={'traefik.enable': 'true', 'traefik.http.routers.traefik': 'true'},
ports={80: self.ports['http'], 443: self.ports['https']})
ports={80: self.ports['http'], 443: self.ports['https']}
)
except DockerException as error:
raise RuntimeError("Can't start proxy ...({})".format(error))

0 comments on commit d03c775

Please sign in to comment.