Sha256: a38a2c7abe6ba5a2a44e36d819297062b944260e8385a41d81b5f547122d23c8
Contents?: true
Size: 793 Bytes
Versions: 1
Compression:
Stored size: 793 Bytes
Contents
# frozen_string_literal: true require 'rake' namespace :data_plane_api do namespace :server do desc "Set the server's admin state to DRAIN through the HAProxy Data Plane API" task :set_drain do next if no_haproxy? ::Capistrano::DataPlaneApi.server_set_drain fetch(:stage), force: force_haproxy? end desc "Set the server's admin state to READY through the HAProxy Data Plane API" task :set_ready do next if no_haproxy? sleep 3 ::Capistrano::DataPlaneApi.server_set_ready fetch(:stage) end desc "Set the server's admin state to MAINT through the HAProxy Data Plane API" task :set_maint do next if no_haproxy? sleep 3 ::Capistrano::DataPlaneApi.server_set_maint fetch(:stage), force: true end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
capistrano-data_plane_api-0.1.0 | lib/capistrano/data_plane_api/tasks.rb |