diff options
author | Pawel Wieczorek <p.wieczorek2@samsung.com> | 2019-07-29 11:47:26 +0200 |
---|---|---|
committer | Pawel Wieczorek <p.wieczorek2@samsung.com> | 2019-07-31 15:47:41 +0200 |
commit | 595116580615502e0a0e70a9e1b906c6c41477af (patch) | |
tree | bf01ced346c7c2226449b7b7eec9e630a336b18c /test/security/k8s/vagrant/dublin | |
parent | 64092cb637805d0d12d08488cdb19a0ada136fd6 (diff) |
k8s: Make operator machine destruction graceful
Issue-ID: SECCOM-235
Change-Id: I9913d9a8f525b4b9582bf821008dd567258a719c
Signed-off-by: Pawel Wieczorek <p.wieczorek2@samsung.com>
Diffstat (limited to 'test/security/k8s/vagrant/dublin')
-rw-r--r-- | test/security/k8s/vagrant/dublin/Vagrantfile | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/security/k8s/vagrant/dublin/Vagrantfile b/test/security/k8s/vagrant/dublin/Vagrantfile index ef4d42b14..148903773 100644 --- a/test/security/k8s/vagrant/dublin/Vagrantfile +++ b/test/security/k8s/vagrant/dublin/Vagrantfile @@ -79,6 +79,7 @@ $link_cluster_yml = <<-SCRIPT SCRIPT $rke_up = "rke up" +$rke_down = "rke remove --force" Vagrant.configure('2') do |config| all.each do |machine| @@ -145,6 +146,10 @@ Vagrant.configure('2') do |config| config.vm.post_up_message = operation_post_msg config.vm.provision "rke_up", type: :shell, run: "never", privileged: false, inline: $rke_up + config.trigger.before :destroy do |trigger| + trigger.warn = "Removing cluster" + trigger.run_remote = {privileged: false, inline: $rke_down} + end end end end |