From f317c168522d5de8cf7137fe76c0271b0fdce0a4 Mon Sep 17 00:00:00 2001 From: Jonas Juselius Date: Thu, 6 Jul 2017 15:06:44 +0200 Subject: [PATCH] Split nixops deployments. --- deploy.sh | 4 ++++ git.nix | 7 +++++++ deployment.nix => k8s.nix | 26 ++++++++++---------------- 3 files changed, 21 insertions(+), 16 deletions(-) create mode 100755 deploy.sh create mode 100644 git.nix rename deployment.nix => k8s.nix (55%) diff --git a/deploy.sh b/deploy.sh new file mode 100755 index 0000000..80b72ed --- /dev/null +++ b/deploy.sh @@ -0,0 +1,4 @@ +#!/sur/bin/bash + +nixops modify -d $1 $1.nix +nixops deploy -d $1 diff --git a/git.nix b/git.nix new file mode 100644 index 0000000..838b5d8 --- /dev/null +++ b/git.nix @@ -0,0 +1,7 @@ +{ + git01 = { config, lib, pkgs, ... }: + { + deployment.targetHost = "10.253.18.103"; + imports = [ ./git01/configuration.nix ]; + }; +} diff --git a/deployment.nix b/k8s.nix similarity index 55% rename from deployment.nix rename to k8s.nix index 95f6dca..318e070 100644 --- a/deployment.nix +++ b/k8s.nix @@ -1,25 +1,19 @@ { - kube01 = { config, lib, pkgs, ... }: - { - deployment.targetHost = "10.253.18.100"; - imports = [ ./k8s01/configuration.nix ]; - }; - - kube02 = { config, lib, pkgs, ... }: - { - deployment.targetHost = "10.253.18.102"; - imports = [ ./k8s02/configuration.nix ]; - }; - - kubemaster = { config, lib, pkgs, ... }: + k8s00 = { config, lib, pkgs, ... }: { deployment.targetHost = "10.253.18.101"; imports = [ ./k8s00/configuration.nix ]; }; - git01 = { config, lib, pkgs, ... }: + k8s01 = { config, lib, pkgs, ... }: { - deployment.targetHost = "10.253.18.103"; - imports = [ ./git01/configuration.nix ]; + deployment.targetHost = "10.253.18.100"; + imports = [ ./k8s01/configuration.nix ]; + }; + + k8s02 = { config, lib, pkgs, ... }: + { + deployment.targetHost = "10.253.18.102"; + imports = [ ./k8s02/configuration.nix ]; }; }