Require DB to run mev-deployment

This commit is contained in:
Luke Van Seters 2021-09-14 12:33:09 -04:00
parent dd7088912a
commit 15af8269e3

View File

@ -1,22 +1,23 @@
load('ext://helm_remote', 'helm_remote') load("ext://helm_remote", "helm_remote")
helm_remote("postgresql", helm_remote("postgresql",
repo_name='bitnami', repo_name="bitnami",
repo_url='https://charts.bitnami.com/bitnami', repo_url="https://charts.bitnami.com/bitnami",
set=["postgresqlPassword=password", "postgresqlDatabase=mev_inspect"], set=["postgresqlPassword=password", "postgresqlDatabase=mev_inspect"],
) )
load('ext://secret', 'secret_from_dict') load("ext://secret", "secret_from_dict")
k8s_yaml(secret_from_dict("mev-inspect-db-credentials", inputs = { k8s_yaml(secret_from_dict("mev-inspect-db-credentials", inputs = {
"username" : "postgres", "username" : "postgres",
"password": "password", "password": "password",
})) }))
docker_build('mev-inspect', '.', docker_build("mev-inspect", ".",
live_update=[ live_update=[
sync('.', '/app'), sync(".", "/app"),
run('cd /app && poetry install', run("cd /app && poetry install",
trigger='./pyproject.toml'), trigger="./pyproject.toml"),
], ],
) )
k8s_yaml("k8s/app.yaml") k8s_yaml("k8s/app.yaml")
k8s_resource(workload="mev-inspect-deployment", resource_deps=["postgresql-postgresql"])