Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds DASH_HOST env variable #1111

Closed
wants to merge 19 commits into from
Closed

Adds DASH_HOST env variable #1111

wants to merge 19 commits into from

Conversation

OwenMatsuda
Copy link
Contributor

@OwenMatsuda OwenMatsuda commented Feb 5, 2020

This PR adds the ability to set a DASH_HOST environment variable to change the host value when running the server.

Testing

  • Check to see if injecting an environment variable changes the host

No Env

  • Make sure that it defaults to 127.0.0.1 if no environment variable

Env

  • If the host parameter is in app.runserver(), then it will take preference over the environment variable. In this case, the argument was host=127.0.0.1

Env & Parameter

Marc-André Rivet added 18 commits August 27, 2019 16:42
# Conflicts:
#	dash-renderer/package-lock.json
# Conflicts:
#	dash-renderer/package-lock.json
# Conflicts:
#	dash-renderer/package-lock.json
- update build artifacts
- update renderer artifacts
- stricten dash dependencies versions
…o iframe-sandbox-support

- Update build artifacts

# Conflicts:
#	dash-renderer/src/AccessDenied.react.js
#	dash-renderer/src/actions/index.js
#	tests/integration/renderer/test_iframe.py
@OwenMatsuda
Copy link
Contributor Author

@alexcjohnson Please review

@josegonzalez
Copy link
Contributor

DashR now uses HOST for this plotly/dashR#167

@OwenMatsuda
Copy link
Contributor Author

DashR now uses HOST for this plotly/dashR#167

Should I just essentially copy the DashR change then and add PORT too?

@OwenMatsuda
Copy link
Contributor Author

def run_server(
        self,
        host=os.getenv('HOST', "127.0.0.1"),
        port=os.getenv('PORT', 8050),
        ...
)

@josegonzalez
Copy link
Contributor

I'd guess so but will leave that decision to others :)

@OwenMatsuda
Copy link
Contributor Author

Moved to #1134 because I accidentally rebased off of master instead of dev.

@OwenMatsuda OwenMatsuda deleted the dash-host branch February 27, 2020 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants