The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

aws-code-deploy: S3 location and command

AZZ
February 22, 2023

Hello,

a few questions

how can I specify a location (path) on a bucket where I'd like to deploy the artifacts?

As of right now, it appears that S3_BUCKET only takes the bucket name e.g. s3://mybucket

 

"Command":

 is there a way to combine both actions ( "upload" and "deploy") without invoking the pipe twice?

 

Thank you.

ref: https://bitbucket.org/atlassian/aws-code-deploy/src/master/README.md

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

1 vote
Answer accepted
Oleksandr Kyrdan
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 24, 2023

Hi @AZZ 

Thank you for your question!

1) there is an example in the Readme for your case:

script:
  - pipe: atlassian/aws-code-deploy:1.1.1
    variables:
      AWS_DEFAULT_REGION: 'ap-southeast-2'
      AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID
      AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY
      COMMAND: 'deploy'
      APPLICATION_NAME: 'lambda-application'
      DEPLOYMENT_GROUP: 'my-deployment-group'
      WAIT: 'true'
      S3_BUCKET: 'my-bucket'
      VERSION_LABEL: 'lambda-app-1.0.0'
      BUNDLE_TYPE: 'YAML'

2) the pipe supports `upload` or `deploy` mode in the current implementation.

Best regards,
Oleksandr Kyrdan

AZZ
February 24, 2023

@Oleksandr Kyrdan,

Thank you for the reply.

If I understood you correctly:

1.  there is no way to specify a path on the bucket? I was hoping to upload to a specific location e.g. "mybucket/deployments".

2. There is no option to upload and deploy in the same pipe call?

Oleksandr Kyrdan
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
February 24, 2023

@AZZ 

1. You could provide the FOLDER variable for the pipe to specify path on you S3 bucket according to the Readme documentation.

FOLDER If the deployable artifact is in any folder inside bucket, specify the folder name

2. You should choose only one of the option or upload or deploy at once.

Like Steffen Opel _Utoolity_ likes this
AZZ
February 27, 2023

worked like a charm. Thank you @Oleksandr Kyrdan 

azam pasha
May 7, 2025
  • Using pipe: atlassian/aws-code-deploy:1.6.0 with FOLDER and S3_BUCKET options.
  • Artifact uploads correctly to the specified S3 path and triggers a deployment in AWS CodeDeploy.
  • However, the uploaded file has a MIME type of binary/octet-stream instead of application/zip.
  • This causes the artifact to not be recognized as a zip file when downloaded from S3.

can you please help here 

DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events