Sha256: a8b492d41941150ac24fab97048379108b51667e58249221c0d2b45c13269c27
Contents?: true
Size: 759 Bytes
Versions: 2
Compression:
Stored size: 759 Bytes
Contents
# Capistrano plugin hook to set default values namespace :load do task :defaults do ssh_options = fetch(:ssh_options, {}).merge( auth_methods: %w(gssapi-with-mic publickey hostbased password keyboard-interactive) ) set :ssh_options, **ssh_options end end desc "execute command on all servers" task :remote_execute, :command do |_task, args| raise ArgumentError, 'remote_execute task requires an argument' unless args[:command] # see https://github.com/mattbrictson/airbrussh/tree/v1.5.2?tab=readme-ov-file#capistrano-34x Airbrussh.configure do |config| config.truncate = false end on roles(:all) do |host| info args[:command] if fetch(:log_level) == :debug info "#{host}:\n#{capture(args[:command])}" end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
dlss-capistrano-5.3.0 | lib/dlss/capistrano/tasks/remote_execute.rake |
dlss-capistrano-5.2.0 | lib/dlss/capistrano/tasks/remote_execute.rake |