Sha256: 35b8b234b0d36287f089c743bb506493dd4c488b606663278f66bc601f1949dd

Contents?: true

Size: 875 Bytes

Versions: 19

Compression:

Stored size: 875 Bytes

Contents

#!/usr/bin/env ruby
require "pathname"
bin_file = Pathname.new(__FILE__).realpath
$:.unshift File.expand_path("../../lib", bin_file)

require 'soar_authentication_token'
require 'thor'

class RotateConfigCLI < Thor
  desc "rotate [OPTIONS]", "rotate configurations"
  option :generator_config_file,  :aliases => '-g',  :desc => 'Configuration file of the generator'
  option :validator_config_file,  :aliases => '-v',  :desc => 'Configuration file of the validator'
  def rotate
    raise 'generator_config_file must be specified' unless options['generator_config_file']

    rotator = SoarAuthenticationToken::ConfigRotator.new
    rotator.rotate_json_config_files(generator_file_name: options['generator_config_file'],
                                     validator_file_name: options['validator_config_file'])
  end
  default_task :rotate
end

RotateConfigCLI.start(ARGV)

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
soar_authentication_token-7.1.1 bin/rotate-configs
soar_authentication_token-7.1.0 bin/rotate-configs
soar_authentication_token-7.0.1 bin/rotate-configs
soar_authentication_token-7.0.0 bin/rotate-configs
soar_authentication_token-6.1.1 bin/rotate-configs
soar_authentication_token-6.1.0 bin/rotate-configs
soar_authentication_token-6.0.9 bin/rotate-configs
soar_authentication_token-6.0.8 bin/rotate-configs
soar_authentication_token-6.0.7 bin/rotate-configs
soar_authentication_token-6.0.5 bin/rotate-configs
soar_authentication_token-6.0.4 bin/rotate-configs
soar_authentication_token-6.0.3 bin/rotate-configs
soar_authentication_token-6.0.2 bin/rotate-configs
soar_authentication_token-6.0.1 bin/rotate-configs
soar_authentication_token-6.0.0 bin/rotate-configs
soar_authentication_token-5.0.3 bin/rotate-configs
soar_authentication_token-5.0.2 bin/rotate-configs
soar_authentication_token-5.0.1 bin/rotate-configs
soar_authentication_token-5.0.0 bin/rotate-configs