Page Menu
Home
GRNET
Search
Configure Global Search
Log In
Files
F324316
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Nov 25, 2:52 PM
Size
1 KB
Mime Type
text/x-diff
Expires
Wed, Nov 27, 2:52 PM (1 d, 14 h)
Engine
blob
Format
Raw Data
Handle
156153
Attached To
rWEBDNS WebDNS (edet4)
View Options
diff --git a/dnsworker/fabfile.py b/dnsworker/fabfile.py
index 6da9aa8..8ed68a6 100644
--- a/dnsworker/fabfile.py
+++ b/dnsworker/fabfile.py
@@ -1,32 +1,34 @@
from fabric.api import env, cd
from fabric.operations import run, put, sudo
env.hosts = ['dnssec-edet4.grnet.gr']
def setup():
put('dnsworker.service', '/etc/systemd/system/', use_sudo=True)
sudo('systemctl daemon-reload')
sudo('systemctl enable dnsworker.service')
def check():
run('test -d /run/systemd/system')
run('test -f /etc/dnsworker/cfg.yml')
run('systemctl is-enabled dnsworker.service')
def restart():
sudo('systemctl restart dnsworker.service')
def install_cron():
put('cron', '/etc/cron.d/dnsworker', use_sudo=True)
+ sudo('chown root:root /etc/cron.d/dnsworker')
def copy():
sudo('mkdir -p /srv/dnsworker')
with cd('/srv/dnsworker'):
put('lib', '.', use_sudo=True)
put('bin', '.', use_sudo=True, mode=0755)
+ sudo('chown -R root:root /srv/dnsworker')
def deploy():
check()
restart()
install_cron()
Event Timeline
Log In to Comment