Skip to content

Commit

Permalink
Merge pull request #332 from aws/1.4.0-release
Browse files Browse the repository at this point in the history
1.4.0 release
  • Loading branch information
mwjones-aws authored Sep 16, 2022
2 parents 429dfe8 + 83a1f45 commit 1a53e8f
Show file tree
Hide file tree
Showing 27 changed files with 611 additions and 859 deletions.
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ require 'rake/packagetask'
require 'rake/testtask'
require 'rspec/core/rake_task'
require 'rubygems'
require 'yaml'
require 'cucumber'

# Run all units tests in test/
desc "Run unit tests in test/"
Expand Down
3 changes: 2 additions & 1 deletion bin/codedeploy-local
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ Options
The format of the application revision bundle. Supported types include tgz, tar, zip, and directory. If you do not specify a type, the tool uses directory by default. If you specify --type, you must also specify --bundle-location. [default: directory]
-b, --file-exists-behavior <value>
Indicates how files are handled that already exist in a deployment target location but weren't part of a previous successful deployment. Options include DISALLOW, OVERWRITE, RETAIN. [default: #{InstanceAgent::Plugins::CodeDeployPlugin::DeploymentSpecification::DEFAULT_FILE_EXISTS_BEHAVIOR}].
Indicates how files are handled that already exist in a deployment target location but weren't part of a previous successful deployment. Options include DISALLOW, OVERWRITE, RETAIN. [default: #{InstanceAgent::Plugins::CodeDeployPlugin::DeploymentSpecification::DEFAULT_FILE_EXISTS_BEHAVIOR}].
Note: this setting can be overriden during individual deployments using the appspec file, which takes precedence over this option setting during that deployment installation.
See also: "create-deployment" in the AWS CLI Reference for AWS CodeDeploy.
-g, --deployment-group <value>
Expand Down
17 changes: 13 additions & 4 deletions bin/install
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ EOF
package_file.write(s3.read)
end
rescue *exceptions => e
@log.error("Could not find package to download at '#{uri.to_s}' - Retrying... Attempt: '#{retries.to_s}'")
@log.warn("Could not find package to download at '#{uri.to_s}' - Retrying... Attempt: '#{retries.to_s}'")
if (retries < 5)
sleep 2 ** retries
retries += 1
Expand All @@ -415,14 +415,23 @@ end
uri = s3_bucket.object_uri(key)
@log.info("Endpoint: #{uri}")

retries ||= 0
exceptions = [OpenURI::HTTPError, OpenSSL::SSL::SSLError, Errno::ETIMEDOUT]
begin
require 'json'

version_string = uri.read(:ssl_verify_mode => OpenSSL::SSL::VERIFY_PEER, :redirect => true, :read_timeout => 120, :proxy => @http_proxy)
JSON.parse(version_string)
rescue OpenURI::HTTPError => e
@log.error("Could not find version file to download at '#{uri.to_s}'")
exit(1)
rescue *exceptions => e
@log.warn("Could not find version file to download at '#{uri.to_s}' - Retrying... Attempt: '#{retries.to_s}'")
if (retries < 5)
sleep 2 ** retries
retries += 1
retry
else
@log.error("Could not download CodeDeploy Agent version file. Exiting Install script.")
exit(1)
end
end
end

Expand Down
Loading

0 comments on commit 1a53e8f

Please sign in to comment.