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

The apache service is not notified when settings.py is updated #170

Closed
rnelson0 opened this issue Mar 13, 2017 · 1 comment
Closed

The apache service is not notified when settings.py is updated #170

rnelson0 opened this issue Mar 13, 2017 · 1 comment
Labels
bug Something isn't working

Comments

@rnelson0
Copy link
Member

While changing some configuration elements, I noticed that changes to settings.py do not notify the apache service to restart. Until that is done manually, the old settings are still used. Here's the agent run:

# sudo puppet agent -t --environment puppetboardpe
Info: Using configured environment 'puppetboardpe'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Loading facts
Info: Caching catalog for puppetboard.example.com
Info: Applying configuration version '1489274497'
Notice: /Stage[main]/Profile::Puppetboard/File[/etc/puppetlabs/puppet/ssl/private_keys]/mode: mode changed '0750' to '0755'
Notice: /Stage[main]/Profile::Puppetboard/File[/etc/puppetlabs/puppet/ssl/private_keys/puppetboard.example.com.pem]/mode: mode changed '0640' to '0644'
Notice: /Stage[main]/Puppetboard/File[/srv/puppetboard/puppetboard/settings.py]/content:
--- /srv/puppetboard/puppetboard/settings.py    2017-03-11 23:20:54.296005740 +0000
+++ /tmp/puppet-file20170311-8162-zqcf25        2017-03-11 23:21:54.849171311 +0000
@@ -2,8 +2,10 @@
 DEV_LISTEN_PORT = 5000
 LOGLEVEL = 'info'
 PUPPETDB_HOST = 'puppet.example.com'
-PUPPETDB_PORT = 8080
-PUPPETDB_SSL_VERIFY = False
+PUPPETDB_PORT = 8081
+PUPPETDB_SSL_VERIFY = True
+PUPPETDB_KEY = '/etc/puppetlabs/puppet/ssl/private_keys/puppetboard.example.com.pem'
+PUPPETDB_CERT = '/etc/puppetlabs/puppet/ssl/certs/puppetboard.example.com.pem'
 PUPPETDB_TIMEOUT = 20
 UNRESPONSIVE_HOURS = 3
 ENABLE_CATALOG = False

Info: Computing checksum on file /srv/puppetboard/puppetboard/settings.py
Info: FileBucket got a duplicate file {md5}74a09228c99782c8abf70b3dfc024c12
Info: /Stage[main]/Puppetboard/File[/srv/puppetboard/puppetboard/settings.py]: Filebucketed /srv/puppetboard/puppetboard/settings.py to puppet with sum 74a09228c99782c8abf70b3dfc024c12
Notice: /Stage[main]/Puppetboard/File[/srv/puppetboard/puppetboard/settings.py]/content: content changed '{md5}74a09228c99782c8abf70b3dfc024c12' to '{md5}76e62b1e6dd1a3b4186ff32e58c49d52'
Notice: Applied catalog in 6.92 seconds

Subsequently, accessing the site returned a 500 and logs showed port 8080 was still being used:

[Sat Mar 11 23:03:43.883756 2017] [:error] [pid 18276] INFO:requests.packages.urllib3.connectionpool:Starting new HTTP connection (28): puppet.example.com
[Sat Mar 11 23:03:43.885765 2017] [:error] [pid 18276] ERROR:pypuppetdb.api:Could not reach PuppetDB on puppet.example.com:8080 over HTTP.

I would expect that changes to settings.py, and possibly other settings-related changes, would notify the apache service to restart.

@wyardley wyardley added the bug Something isn't working label Sep 17, 2017
br0ch0n added a commit to br0ch0n/puppet-puppetboard that referenced this issue Nov 1, 2018
Change-Id: Id06b3870d1e7e3986dd9ffa2c0cadc4730c96be6
@smortex
Copy link
Member

smortex commented Jul 31, 2022

Was fixed in #159

@smortex smortex closed this as completed Jul 31, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants