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

Proxy pass template #2776

Closed
wants to merge 20 commits into from
Closed

Proxy pass template #2776

wants to merge 20 commits into from

Conversation

acozine
Copy link
Contributor

@acozine acozine commented Feb 21, 2022

The template we've been using for proxy pass configuration is more of a file than a template.

This PR pulls the data for proxy passes into its own (alphabetized) vars file, makes the template a template, and adds a task to fill out the template. Separating the data out doesn't reduce maintenance, but it does make the entries more readable, so folks can easily add or edit entries for sites that need proxy passes.

@acozine
Copy link
Contributor Author

acozine commented Feb 22, 2022

Cross-check against

- can we consolidate? Are we duplicating?

We may not currently be able to use proxypass rules in apache, this should be happening on the load balancer. Investigate!

@acozine
Copy link
Contributor Author

acozine commented Feb 24, 2022

This PR now attempts to:

  • consolidate our proxy directives in the nginxplus role
  • delete unused proxy directives from the libwww role
  • record our proxy needs in a vars file
  • use a template to generate nginx config with proxy directives
    Still a bunch of work to be done, but this will be much tidier!

@acozine
Copy link
Contributor Author

acozine commented Feb 24, 2022

Not sure of the correct destination for the /njmaps address in production - probably it should point to lib-static-prod like this and not to libphp-prod like this, but confirm.

@@ -0,0 +1,141 @@
# list of proxy directives
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@acozine the only concept I am not seeing is that we have different proxies for the staging library site and the production library site. For example: https://library.princeton.edu/njmaps/ and https://library-staging.princeton.edu/njmaps/. go to two different places https://lib-static-prod.princeton.edu/njmaps/ for prod and https://firestone-renovations-staging.princeton.edu/njmaps/ for staging. This is pattern is used a lot to proxy the staging version of the page to library-staging.princeton.edu and the production version to library.princeton.edu. This is necessary to test how the page will behave behind the proxy before putting changes into production.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know this is a WIP, so I am just making sure you have that in mind...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, thanks @carolyncole. I will make two files here - one for prod and one for staging.

@acozine
Copy link
Contributor Author

acozine commented Apr 21, 2022

I can't tell why this got closed. I'd guess an automated process that closes Draft PRs after 2 months, except we have older Draft PRs that are still open. When someone actively closes a PR, the message says Person closed this N days ago but this one just says This pull request was closed. This is still something I'd like to work on, so I'm reopening the PR. Chime in if there are reasons to close it and pursue this work on a different path.

@acozine
Copy link
Contributor Author

acozine commented Mar 7, 2023

Closing in favor of #3741.

@acozine acozine closed this Mar 7, 2023
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