Skip to content

Commit

Permalink
prepend key-file path with computed testnet dir
Browse files Browse the repository at this point in the history
  • Loading branch information
O1ahmad committed Aug 31, 2020
1 parent 9c6c84a commit 52e359b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/lib/integration_test_cloud_engine/coda_automation.ml
Original file line number Diff line number Diff line change
Expand Up @@ -369,18 +369,21 @@ module Network_manager = struct

let deploy t =
if t.deployed then failwith "network already deployed" ;
let testnet_dir =
t.network_config.coda_automation_location ^/ "terraform/testnets"
^/ network_config.terraform.testnet_name
let%bind () = run_cmd_exn t "terraform" ["apply"; "-auto-approve"] in
let%map () =
Deferred.List.iter t.keypair_secrets ~f:(fun secret ->
run_cmd_exn t "kubectl"
[ "create"
; "secret"
; "generic"
; t.testnet_dir ^/ secret
; secret
; "--cluster=" ^ t.cluster
; "--namespace=" ^ t.namespace
; "--from-file=key=" ^ secret
; "--from-file=pub=" ^ secret ^ ".pub" ] )
; "--from-file=key=" ^ (testnet_dir ^/ secret)
; "--from-file=pub=" ^ (testnet_dir ^/ secret) ^ ".pub" ] )
in
t.deployed <- true ;
{ Kubernetes_network.constraint_constants= t.constraint_constants
Expand Down

0 comments on commit 52e359b

Please sign in to comment.