Update 'scripts/wallabag/main.py'
parent
1678d5c826
commit
fcd9949cf0
|
@ -1,10 +1,11 @@
|
||||||
import os, sys
|
import os, sys
|
||||||
|
|
||||||
with open("../nginx-site-template.conf", "r") as f:
|
with open("../nginx-site-template.conf", "r") as f:
|
||||||
template = f.read().replace("#serverNameVar", f"server_name {sys.argv[1]};")
|
template = f.read().replace("#serverNameVar", f"{sys.argv[1]};").replace("#http://127.0.0.1:8080/", f"http://172.30.1.1:80/")
|
||||||
|
|
||||||
with open("/etc/nginx/sites-available/wallabag.conf", "w") as f:
|
with open("/etc/nginx/sites-available/wallabag.conf", "w") as f:
|
||||||
f.write(template)
|
f.write(template)
|
||||||
|
|
||||||
# depreceated, TODO: replace with os.subprocess
|
# depreceated, TODO: replace with os.subprocess
|
||||||
os.system("../nginx-ensite.sh wallabag.conf")
|
os.system("sh ../nginx-ensite.sh wallabag.conf")
|
||||||
|
os.system("sh launch-docker.sh")
|
Loading…
Reference in New Issue