Sha256: 0b834729e2940c185a4bbf0f8060706d3c02baeebe842b301e6e69ec977a2ee5
Contents?: true
Size: 626 Bytes
Versions: 34
Compression:
Stored size: 626 Bytes
Contents
module Kontena::Cli::Vpn class RemoveCommand < Kontena::Command include Kontena::Cli::Common include Kontena::Cli::GridOptions option "--force", :flag, "Force remove", default: false, attribute_name: :forced def execute require_api_url token = require_token confirm unless forced? name = 'vpn' vpn = client(token).get("stacks/#{current_grid}/#{name}") rescue nil exit_with_error("VPN stack does not exist") if vpn.nil? spinner "Removing #{pastel.cyan(name)} service " do client(token).delete("stacks/#{current_grid}/#{name}") end end end end
Version data entries
34 entries across 34 versions & 2 rubygems