-
Notifications
You must be signed in to change notification settings - Fork 4
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
First steps to nginx config template #4397
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Left a couple questions, but I really like where this is going!
ansible.builtin.template: | ||
src: http/library.conf.j2 | ||
dest: /tmp/{{ item.name }}.conf | ||
# dest: /etc/nginx/conf.d/{{ item.name }}.conf |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we put in a comment explaining that this is where they will eventually go, once testing is complete, or is that self-explanatory?
proxy_intercept_errors on; | ||
# TODO don't do a health check if there's only one server | ||
{% if item.health_check_URI is defined %} | ||
health_check interval=10 fails=3 passes=2 uri={{ item.health_check_URI }}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could health_check_URI
have a default of /
(which I'm guessing is the nginx default) and thus avoid a conditional? I think it's fine either way, just trying to think of ways to simplify.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm kinda cheating here. We don't want to do health checks on all sites, because for sites with only one server a health check is all overhead and no gain. This way we can use "health_check_URI" tell which sites should have one at all. But yeah, your solution is a good one longer-term.
# vars file for roles/nginxplus | ||
# the 'sites' dictionary is used by the library.conf.j2 template | ||
sites: | ||
# - name: example-prod |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really appreciate this in-file documentation
location: "/" | ||
visibility: private | ||
app_protect: enabled | ||
- name: allsearch-api-prod |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This might not have been in when you started this, but I think you could do allsearch and allsearch-staging as well (in addition to the api-only boxes)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cool! I'll add them in.
Try tigerdata staging and prod, orcid staging and prod. |
462a385
to
80b4544
Compare
For bibdata, we need to have three additional proxy settings:
All are set to |
855266a
to
4ca996c
Compare
Known remaining work to a first-round merge:
|
Gist for current blocker: https://gist.github.com/acozine/889141cde3f713d8c4b26b83fe93d334 |
@sandbergja and I tested the tasks for identifying and removing obsolete dynamic config files today. I added tasks for doing the same for obsolete static config files. I think after the break we can start moving the easy configs over. Procedure:
If that works as expected, then we can merge this PR and migrate one or two configs per PR for the next few months. |
Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com>
Co-authored-by: Christina Chortaria <christinach@users.noreply.github.com>
Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com>
Co-authored-by: Alicia Cozine <acozine@users.noreply.github.com>
Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com>
Co-authored-by: Alicia Cozine <acozine@users.noreply.github.com>
Co-authored-by: Alicia Cozine <acozine@users.noreply.github.com>
Co-authored-by: Alicia Cozine <acozine@users.noreply.github.com>
Co-authored-by: Christina Chortaria <christinach@users.noreply.github.com> Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com> Co-authored-by: Ryan Laddusaw <rladdusaw@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Christina Chortaria <christinach@users.noreply.github.com> Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com> Co-authored-by: Ryan Laddusaw <rladdusaw@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Christina Chortaria <christinach@users.noreply.github.com> Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com> Co-authored-by: Ryan Laddusaw <rladdusaw@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Francis Kayiwa <kayiwa@users.noreply.github.com> Co-authored-by: Vickie Karasic <vickiekarasic@users.noreply.github.com>
Co-authored-by: Jane Sandberg <sandbergja@users.noreply.github.com>
…lete the entire directory when removing a single site
3e9b7c4
to
caaf0e3
Compare
Rebased ahead of the holidays. |
Next (final?) steps for current PR:
Future work before we move our most complicated sites to the config template:
|
More progress today. When the |
Closing in favor of #4654 |
Partial fix for #4349.
This PR:
|
instead of:
in task names in theupload-config.yml
file so we don't have to quote themupload-config.yml
file