ns-ionos: move powerdnsadmin webinterface to new hostname
This commit is contained in:
parent
a4bb7f89ec
commit
f8416215d5
6 changed files with 34 additions and 9 deletions
|
@ -9,7 +9,7 @@ Group=powerdnsadmin
|
|||
Environment=FLASK_CONF=/opt/powerdnsadmin/config.py
|
||||
WorkingDirectory=/opt/powerdnsadmin/src
|
||||
ExecStartPre=-/bin/chown powerdnsadmin:powerdnsadmin /opt/powerdnsadmin/src/powerdnsadmin/static
|
||||
ExecStart=/opt/powerdnsadmin/venv/bin/gunicorn 'powerdnsadmin:create_app()'
|
||||
ExecStart=/opt/powerdnsadmin/venv/bin/gunicorn 'powerdnsadmin:create_app()' --name powerdnsadmin --workers 4 --max-requests 1200 --max-requests-jitter 50 --log-level=info --bind=127.0.0.1:22100
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
|
@ -21,10 +21,14 @@ git_deploy = {
|
|||
files = {
|
||||
'/opt/powerdnsadmin/config.py': {
|
||||
'content_type': 'mako',
|
||||
'triggers': {
|
||||
'svc_systemd:powerdnsadmin:restart',
|
||||
},
|
||||
},
|
||||
'/etc/systemd/system/powerdnsadmin.service': {
|
||||
'triggers': {
|
||||
'action:systemd-reload',
|
||||
'svc_systemd:powerdnsadmin:restart',
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
|
@ -50,3 +50,27 @@ def icinga_check_for_new_release(metadata):
|
|||
},
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
@metadata_reactor.provides(
|
||||
'nginx/vhosts/powerdnsadmin',
|
||||
)
|
||||
def nginx(metadata):
|
||||
if not node.has_bundle('nginx'):
|
||||
raise DoNotRunAgain
|
||||
|
||||
return {
|
||||
'nginx': {
|
||||
'vhosts': {
|
||||
'powerdnsadmin': {
|
||||
'locations': {
|
||||
'/': {
|
||||
'target': 'http://127.0.0.1:22100',
|
||||
},
|
||||
},
|
||||
'website_check_path': '/login',
|
||||
'website_check_string': 'PowerDNS',
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue