I am trying to setup a s3 upload I have an artifact file-1.2.3.zip. I have a script to get the version from the file (1.2.3). Is there a way for me to pass that to the next step> I am setting the variable $current_ver
image: atlassian/default-image:latest
pipelines:
default:
- step:
Name: Install Prerequisite and Build server
caches:
- sbt
- ivy2
- maven
script:
- echo "Download and install Play2"
- wget -O play-2.1.0.zip https://downloads.typesafe.com/play/2.1.0/play-2.1.0.zip
- unzip ./play-2.1.0.zip
- export PATH=$PATH:~/play-2.1.0
- printenv
- ./activator clean compile dist
- cp target/universal/server*.zip ./server-dist.zip
- ver=$(find target/universal/ -name 'server-*.zip'|awk -F"-" '{ print $2 }')
- current_ver=${ver::-4}
artifacts:
- target/universal/server-$current_ver.zip
- step:
name: Upload dist file to s3
script:
- pipe: atlassian/aws-code-deploy:0.2.10
variables:
AWS_DEFAULT_REGION: ap-south-1
AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY
COMMAND: 'upload'
APPLICATION_NAME: 'uServer'
ZIP_FILE: server-$current_ver.zip
S3_BUCKET: 'compant-bucket-artifacts'
@Travis Stevens I see two options here:
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.