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

Ensure pre-production Drupal deployments use the corresponding data environment #75

Open
mfisher87 opened this issue Mar 19, 2024 · 0 comments

Comments

@mfisher87
Copy link
Contributor

This code:

if (window.location.port === "8080") {
return `${window.location.protocol}//${window.location.hostname}`;
}

... handles selecting the correct data for the given environment IFF we're running in a docker-compose style deployment.

However, we also deploy to pre-production Drupal environments as an NPM package, in which case the default production data URL is used. We should be able to detect that we're in an integration.*.nsidc.org URL and select the corresponding pre-production data URL, e.g. https://integration.nsidc.org/api/snow-today.

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

No branches or pull requests

1 participant