Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,466,890
Community Members
 
Community Events
176
Community Groups

AWS Pipeline: Cannot upload a file to S3 eventhough file is present

Hi, folks!

 

I'm trying to do a very simple deploy process with Pipelines and CodeDeploy. However, after I create the zip file and I try to upload it to S3, the pipeline fails saying the file is not present.

 

To be sure the file was present, I added a find command right before the upload command. The find command does result in a hit, but the deploy still fails saying it could not find it. I'm guessing the file is lost because it is not present on the same Docker. Do I have to do everything on the same script and use the Python integration script?


I have attached screenshots to illustrate this situation and my bitbucket-pipeline.yml.

 

Thank you in advance!

 

===================

 

Pipeline Configuration:

script: # Modify the commands below to build your repository. 
- apt-get update && apt-get install zip
[...]
- cat build/include.txt | zip build.zip -@
- find . -name build.zip

- step:
#name: Deploy
name: Upload
deployment: Production - Labs Dynaton

script:
- pipe: atlassian/aws-code-deploy:0.5.0
variables:
AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY
AWS_DEFAULT_REGION: $AWS_DEFAULT_REGION # Optional if already defined in the context.
APPLICATION_NAME: $APPLICATION_NAME
COMMAND: $COMMAND
S3_BUCKET: $S3_BUCKET
ZIP_FILE: 'build.zip' # Trying to pass it hardcoded

 

(pasting here unformatted the YML. Pretend everything is well formatted)

 

 

Screenshots:
Screenshot_20200331_225935.png

 

 

bb-deploy-error.png

1 answer

1 accepted

0 votes
Answer accepted

Solved using Artifacts.

 

https://confluence.atlassian.com/bitbucket/using-artifacts-in-steps-935389074.html

 

I found a little confusing and misleading the documentation - it did not look like I would need to create an artifact.  Nonetheless, it is solved.

 

Cheers!

I agree, the docs are not very clear and there is no comprehensive latest and up to date reference available. I had to piece everything together from various places.

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events