about summary refs log tree commit diff
diff options
context:
space:
mode:
authorWilliam Carroll <wpcarro@gmail.com>2022-02-14T22·22-0800
committerclbot <clbot@tvl.fyi>2022-02-14T22·27+0000
commit9b267dbe99d8b17ba929045694ffa2f577fc6722 (patch)
treeffa7b21cb13e44408939afb495e9b67f4df7a159
parent7ffcc25c1bfe0fcf487bb9a3cc3d556d45fc4382 (diff)
fix(wpcarro/nix): Restore cleanup code for deploy-diogenes r/3832
This was temporarily commented-out and never uncommented.

Change-Id: If770721aa10c65c5601b9f53a2d1810aef57b61d
Reviewed-on: https://cl.tvl.fyi/c/depot/+/5290
Tested-by: BuildkiteCI
Reviewed-by: wpcarro <wpcarro@gmail.com>
Autosubmit: wpcarro <wpcarro@gmail.com>
-rw-r--r--users/wpcarro/nixos/default.nix8
1 files changed, 4 insertions, 4 deletions
diff --git a/users/wpcarro/nixos/default.nix b/users/wpcarro/nixos/default.nix
index de8bb028f1a2..f88f0983c9ec 100644
--- a/users/wpcarro/nixos/default.nix
+++ b/users/wpcarro/nixos/default.nix
@@ -21,10 +21,10 @@ in
       ${pkgs.terraform}/bin/terraform -chdir="$TF_STATE_DIR" init
     fi
 
-    # function cleanup() {
-    #   rm -f "$TF_STATE_DIR/$(basename $STORE_PATH)"
-    # }
-    # trap cleanup EXIT
+    function cleanup() {
+      rm -f "$TF_STATE_DIR/$(basename $STORE_PATH)"
+    }
+    trap cleanup EXIT
 
     ${pkgs.terraform}/bin/terraform -chdir="$TF_STATE_DIR" apply
   '';