OPNsense
  • Home
  • Help
  • Search
  • Login
  • Register

  • OPNsense Forum »
  • English Forums »
  • Development and Code Review (Moderator: fabian) »
  • nginx plugin
« previous next »
  • Print
Pages: 1 2 [3] 4 5 6

Author Topic: nginx plugin  (Read 29554 times)

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #30 on: October 06, 2018, 07:05:11 pm »
Hello!

I've some trouble while trying with multiple upstream servers:

Code: [Select]
nginx: [emerg] "upstream" directive is not allowed here in /usr/local/etc/nginx/nginx.conf:56
nginx: configuration file /usr/local/etc/nginx/nginx.conf test failed

I make a minor change in the upstream.conf jinja template that worked for me:

https://github.com/juliocbc/plugins/commit/82a47c38254691672a002a30e997d08d1e9a9b8e
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #31 on: October 06, 2018, 07:17:54 pm »
Could you please open a pull request so I can merge it?
Logged

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #32 on: October 06, 2018, 08:20:16 pm »
Sure!!

https://github.com/opnsense/plugins/pull/893
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #33 on: October 07, 2018, 08:41:47 am »
I am waiting for the additional approval of Franco, then it will be in the next update.
Logged

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #34 on: October 09, 2018, 01:32:43 pm »
Hi Franz!

I've opened a ISSUE: https://github.com/opnsense/plugins/issues/902

version: os-nginx-devel-1.1

If it is set TLS Certificate option in HTTP Server the following error occurs:

PHP Warning: Invalid argument supplied for foreach() in /usr/local/opnsense/scripts/nginx/setup.php on line 88
Logged
Cloudfence Open Source Team

mimugmail

  • Hero Member
  • *****
  • Posts: 6342
  • Karma: 436
    • View Profile
Re: nginx plugin
« Reply #35 on: October 09, 2018, 01:36:32 pm »
Be sure Fabian is getting notified by any issue via Github :)
Logged
Twitter: mimu_muc
WWW: www.routerperformance.net
Support plans: https://www.max-it.de/en/it-services/opnsense/
Commercial Plugins (German): https://opnsense.max-it.de/

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #36 on: October 09, 2018, 03:48:23 pm »
I tagged his user on the post!!

Thanks!
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #37 on: October 09, 2018, 07:52:20 pm »
fix is provided. Thanks for reporting.
Logged

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #38 on: October 09, 2018, 08:39:21 pm »
@Fabian

Thanks!!

Now the error don't occurs anymore, but the
Code: [Select]
/usr/local/etc/nginx/nginx.conf is don't being updated with the WebGUI configuration.

Is there some additional step?
« Last Edit: October 09, 2018, 08:59:45 pm by juliocbc »
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #39 on: October 09, 2018, 10:49:21 pm »
did you click on the reconfigure button (the one with the two arrows) and there is no error in the configd log?
Logged

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #40 on: October 10, 2018, 12:40:27 pm »
Yes, I did it!

I didn't checked in configd.log (I was looking for errors on system.lof - Old habits  from 16.x  ::) )

Errors in configd.log:

Code: [Select]
Oct 10 10:37:36 OPNsense configd.py: [51c4c4a6-5895-47ff-b5de-136cd80f7624] Inline action failed with OPNsense/Nginx OPNsense/Nginx/nginx.conf 'None' has no attribute '@uuid' at Traceback (most recent call last):   File "/usr/local/opnsense/service/modules/processhandler.py", line 507, in execute     return ph_inline_actions.execute(self, inline_act_parameters)   File "/usr/local/opnsense/service/modules/ph_inline_actions.py", line 51, in execute     filenames = tmpl.generate(parameters)   File "/usr/local/opnsense/service/modules/template.py", line 332, in generate     raise render_exception Exception: OPNsense/Nginx OPNsense/Nginx/nginx.conf 'None' has no attribute '@uuid'
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #41 on: October 10, 2018, 05:42:50 pm »
this could be everything but I've provided a fix for that as far as I know in core. Did you delete anything?
Logged

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #42 on: October 10, 2018, 06:26:37 pm »
Nope...

I'll try to make again the devel package with the latest commits then...

Logged
Cloudfence Open Source Team

juliocbc

  • Sr. Member
  • ****
  • Posts: 264
  • Karma: 11
    • View Profile
    • Cloudfence
Re: nginx plugin
« Reply #43 on: October 10, 2018, 06:46:44 pm »
The os-nginx-devel, I've get a new git clone from plugins repo and make again the package.

I've removed the packages os-nginx-devel and nginx and reinstalled both.

Am I missing something?
Logged
Cloudfence Open Source Team

fabian

  • Moderator
  • Hero Member
  • *****
  • Posts: 2768
  • Karma: 199
  • OPNsense Contributor (Language, VPN, Proxy, etc.)
    • View Profile
    • Personal Homepage
Re: nginx plugin
« Reply #44 on: October 10, 2018, 09:40:46 pm »
are you also on opnsense devel?
Logged

  • Print
Pages: 1 2 [3] 4 5 6
« previous next »
  • OPNsense Forum »
  • English Forums »
  • Development and Code Review (Moderator: fabian) »
  • nginx plugin
 

OPNsense is an OSS project © Deciso B.V. 2015 - 2023 All rights reserved
  • SMF 2.0.19 | SMF © 2021, Simple Machines
    Privacy Policy
    | XHTML | RSS | WAP2