bin/s3_website in s3_website-2.2.0 vs bin/s3_website in s3_website-2.3.0

- old
+ new

@@ -21,10 +21,20 @@ rescue Exception => error puts "#{error.message} (#{error.class})" exit 1 end + option( + :headless, + :type => :boolean, + :desc => "Apply the settings headlessly. See --autocreate-cloudfront-distribution for more info." + ) + option( + 'autocreate-cloudfront-dist', + :type => :boolean, + :desc => "When used with --headless, automatically create a CloudFront distribution for your S3 website." + ) desc 'apply', 'Apply the configuration on the AWS services' long_desc <<-LONGDESC `s3_website cfg apply` will apply the configuration the S3 bucket. In addition, if you CloudFront related settings, this command will apply them on the CloudFront distribution. @@ -35,10 +45,12 @@ def apply puts 'Applying the configurations in s3_website.yml on the AWS services ...' require 'configure-s3-website' config_source = ConfigureS3Website::FileConfigSource.new 's3_website.yml' ConfigureS3Website::Runner.run({ - :config_source => config_source + :config_source => config_source, + :headless => options[:headless], + 'autocreate-cloudfront-dist' => options['autocreate-cloudfront-dist'] }) rescue Exception => error puts "#{error.message} (#{error.class})" exit 1 end