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

Nginx shim for local_vars_big #2009

Closed
wants to merge 6 commits into from
Closed

Conversation

georgejhunt
Copy link
Contributor

Tested on RPI 4, and vm's(buster,ubunti18).

This started out as a shim, proxying everything to apache.
But now there are many services served directly by nginx (see https://github.com/georgejhunt/iiab/blob/nginx/roles/nginx/files/README.md)

@holta holta added this to the 7.1 milestone Oct 16, 2019
Copy link
Contributor

@jvonau jvonau left a comment

Choose a reason for hiding this comment

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

see comments inline below

state: link
when: awstats_enabled and is_debuntu

- name: Remove symlink from sites-enabled, to disable AWStats (debuntu)
Copy link
Contributor

Choose a reason for hiding this comment

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

Should be ported to remove awstats-nginx.conf when not awstats_enabled

@@ -108,11 +108,17 @@
state: restarted
when: calibreweb_enabled | bool

- name: Restart nginx systemd service
Copy link
Contributor

Choose a reason for hiding this comment

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

should disable - name: Restart Apache systemd service, below not used going direct to port

@@ -123,6 +124,7 @@
- headers
- proxy
- proxy_html
- headers
Copy link
Contributor

Choose a reason for hiding this comment

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

duplicate entry

@@ -119,6 +119,18 @@
# name: proxy_http

- name: Start 'kolibri' systemd service, if kolibri_enabled
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe Installing files....

@@ -159,7 +171,7 @@
value: "{{ kolibri_url }}"
- option: kolibri_exec_path
value: "{{ kolibri_exec_path }}"
- option: kolibri_http_port
- option: kolibri_port
Copy link
Contributor

Choose a reason for hiding this comment

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

going direct to port, a2ensite, a2dissite, and apache should be commented out above.

Copy link
Contributor

Choose a reason for hiding this comment

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

Based on the migrated list in the README, is there a missing kolibri-nginx.conf for the proxy_pass to apache or to proxy the kolibri_url to the port directly?

state: link
when: munin_enabled and is_debuntu

- name: Remove symlink /etc/apache2/sites-enabled/munin24.conf if not munin_enabled (debuntu)
Copy link
Contributor

Choose a reason for hiding this comment

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

should remove /etc/nginx/conf.d/munin24-nginx.conf if disabled

state: link
when: sugarizer_enabled and is_debuntu

- name: Remove symlink /etc/apache2/sites-enabled/sugarizer.conf (if not sugarizer_enabled)
Copy link
Contributor

Choose a reason for hiding this comment

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

remove /etc/nginx/conf.d/sugarizer-nginx.conf'

@@ -277,6 +270,12 @@
# state: stopped
# when: not sugarizer_enabled

- name: Restart nginx when enabled
Copy link
Contributor

Choose a reason for hiding this comment

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

please # out apache restart call above



upstream kalite {
server 127.0.0.1:7007;
Copy link
Contributor

Choose a reason for hiding this comment

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

what sets the port used at 7007 when kalite_server_port: 8008 is in default_vars.yml?

nginx_port: "80"
nginx_interface: "0.0.0.0"
nginx_install: True
nginx_enabled: True
Copy link
Contributor

Choose a reason for hiding this comment

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

below kalite_server_port: should be set to 7007

@georgejhunt georgejhunt mentioned this pull request Oct 17, 2019
@holta holta mentioned this pull request Oct 18, 2019
@@ -0,0 +1,13 @@
Unit]
Copy link
Contributor

Choose a reason for hiding this comment

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

missing [

@georgejhunt
Copy link
Contributor Author

georgejhunt commented Oct 20, 2019 via email

@georgejhunt
Copy link
Contributor Author

incorporated in gh-nginx-e

@georgejhunt georgejhunt closed this Dec 6, 2019
@georgejhunt georgejhunt deleted the nginx branch December 15, 2019 05:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants