forked from Fediversity/Fediversity
account for 285
This commit is contained in:
parent
ec47484186
commit
84e5b67d25
1 changed files with 12 additions and 5 deletions
|
@ -23,6 +23,10 @@ class Index(TemplateView):
|
||||||
template_name = 'index.html'
|
template_name = 'index.html'
|
||||||
|
|
||||||
|
|
||||||
|
class Index(TemplateView):
|
||||||
|
template_name = 'index.html'
|
||||||
|
|
||||||
|
|
||||||
class AccountDetail(LoginRequiredMixin, DetailView):
|
class AccountDetail(LoginRequiredMixin, DetailView):
|
||||||
model = User
|
model = User
|
||||||
template_name = 'account_detail.html'
|
template_name = 'account_detail.html'
|
||||||
|
@ -109,6 +113,12 @@ class DeploymentStatus(ConfigurationForm):
|
||||||
# pass in form info to our deployment
|
# pass in form info to our deployment
|
||||||
"DEPLOYMENT": config.json()
|
"DEPLOYMENT": config.json()
|
||||||
}
|
}
|
||||||
|
# XXX should we not log this if it may show proxmox credentials from `.envrc`s?
|
||||||
|
# those could instead be passed as sensitive TF vars, but that would not address this.
|
||||||
|
logger.debug("env: %s", env)
|
||||||
|
cwd = f"{settings.repo_dir}/launch"
|
||||||
|
# direnv wants this run upfront, and chaining in subprocess feels awkward
|
||||||
|
subprocess.check_call(["direnv", "allow"], cwd=cwd)
|
||||||
cmd = [
|
cmd = [
|
||||||
"nix",
|
"nix",
|
||||||
"develop",
|
"develop",
|
||||||
|
@ -119,9 +129,6 @@ class DeploymentStatus(ConfigurationForm):
|
||||||
"apply",
|
"apply",
|
||||||
"test",
|
"test",
|
||||||
]
|
]
|
||||||
deployment_result = subprocess.run(
|
deployment_result = subprocess.run(cmd, cwd=cwd, env=env)
|
||||||
cmd,
|
logger.debug("deployment_result: %s", deployment_result)
|
||||||
cwd=settings.repo_dir,
|
|
||||||
env=env,
|
|
||||||
)
|
|
||||||
return deployment_result, config
|
return deployment_result, config
|
||||||
|
|
Loading…
Add table
Reference in a new issue