Skip to content

Commit

Permalink
ENH: Listen on autodiscovered address and forward standard port with …
Browse files Browse the repository at this point in the history
…docker
  • Loading branch information
gotiniens committed Jun 14, 2021
1 parent 24bcfbd commit 191b7bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
1 change: 1 addition & 0 deletions run_docker.sh
Expand Up @@ -4,6 +4,7 @@ docker build . -t wkz
docker run \
--name workoutizer \
--rm \
-p 8000:8000 \
-it \
-v $(pwd):/wkz \
wkz \
Expand Down
6 changes: 1 addition & 5 deletions workoutizer/cli.py
Expand Up @@ -50,11 +50,7 @@ def _is_main_run():
"being passed, it will be determined automatically. Usage, e.g.: 'wkz run 0.0.0.0:8000'."
)
def run(url):
if not url:
if os.getenv("WKZ_ENV") == "devel":
url = "127.0.0.1:8000"
else:
url = f"{get_local_ip_address()}:8000"
url = f"{get_local_ip_address()}:8000"
if _is_main_run():
click.echo(f"using workoutizer home at {WORKOUTIZER_DIR}")
with HueyManager():
Expand Down

0 comments on commit 191b7bf

Please sign in to comment.