duh
This commit is contained in:
25
caddy.py
25
caddy.py
@@ -3,16 +3,15 @@ from textwrap import dedent
|
||||
from deploy import by_branch
|
||||
|
||||
|
||||
def build_caddyfile():
|
||||
excluded = {"deployer"}
|
||||
with open("Caddyfile", "w+") as file:
|
||||
for domain, port in map(itemgetter("domain", "port"), by_branch.values()):
|
||||
if domain in excluded:
|
||||
continue
|
||||
print(f"adding {domain} -> {port} to Caddyfile")
|
||||
entry = f"""
|
||||
{domain}.drm.dev {{
|
||||
reverse_proxy localhost:{port}
|
||||
}}
|
||||
"""
|
||||
file.write(dedent(entry))
|
||||
excluded = {"deployer"}
|
||||
with open("Caddyfile", "w+") as file:
|
||||
for domain, port in map(itemgetter("domain", "port"), by_branch.values()):
|
||||
if domain in excluded:
|
||||
continue
|
||||
print(f"adding {domain} -> {port} to Caddyfile")
|
||||
entry = f"""
|
||||
{domain}.drm.dev {{
|
||||
reverse_proxy localhost:{port}
|
||||
}}
|
||||
"""
|
||||
file.write(dedent(entry))
|
||||
|
||||
Reference in New Issue
Block a user