forked from fediversity/fediversity
Compare commits
4 commits
862d6ba2b7
...
4d68edb69d
| Author | SHA1 | Date | |
|---|---|---|---|
| 4d68edb69d | |||
| 5749ac17a5 | |||
| c054828ad3 | |||
| da8c157bc5 |
1 changed files with 3 additions and 17 deletions
|
|
@ -6,11 +6,9 @@
|
||||||
{
|
{
|
||||||
_class = "nixosTest";
|
_class = "nixosTest";
|
||||||
|
|
||||||
name = "deployment-model";
|
name = "deployment-basic";
|
||||||
|
|
||||||
sourceFileset = lib.fileset.unions [
|
sourceFileset = lib.fileset.unions [
|
||||||
../../data-model.nix
|
|
||||||
../../function.nix
|
|
||||||
./constants.nix
|
./constants.nix
|
||||||
./deployment.nix
|
./deployment.nix
|
||||||
];
|
];
|
||||||
|
|
@ -18,6 +16,7 @@
|
||||||
nodes.deployer =
|
nodes.deployer =
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
|
|
||||||
# FIXME: sad times
|
# FIXME: sad times
|
||||||
system.extraDependencies = with pkgs; [
|
system.extraDependencies = with pkgs; [
|
||||||
jq
|
jq
|
||||||
|
|
@ -39,21 +38,8 @@
|
||||||
hello.fail("hello 1>&2")
|
hello.fail("hello 1>&2")
|
||||||
cowsay.fail("cowsay 1>&2")
|
cowsay.fail("cowsay 1>&2")
|
||||||
|
|
||||||
# SETTINGS.BIN_PATH
|
|
||||||
# CONFIG
|
|
||||||
env = {
|
|
||||||
"PATH": settings.bin_path,
|
|
||||||
# "TF_LOG": "info",
|
|
||||||
} | {
|
|
||||||
# pass in form info to our deployment
|
|
||||||
# FIXME: ensure sensitive info is protected
|
|
||||||
f"TF_VAR_{k}": v if isinstance(v, str) else json.dumps(v) for k, v in json.loads(config.model_dump_json()).items()
|
|
||||||
}
|
|
||||||
|
|
||||||
# USE ENV
|
|
||||||
# SETTINGS.REPO_DIR
|
|
||||||
with subtest("Run the deployment"):
|
with subtest("Run the deployment"):
|
||||||
deployer.succeed("cd ${settings.repo_dir}/infra/operator && tofu apply --auto-approve -lock=false -parallelism=1")
|
deployer.succeed("nixops4 apply check-deployment-basic --show-trace --no-interactive 1>&2")
|
||||||
|
|
||||||
with subtest("Check the deployment"):
|
with subtest("Check the deployment"):
|
||||||
hello.succeed("hello 1>&2")
|
hello.succeed("hello 1>&2")
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue