At this moment I have a Springboot Application (Maven), I want to implement CI/CD with Bitbucket Pipelines and AWS CodeDeploy, but I don't really understand how I can do it, I already see the maven build template, however , I don't know how can implement the AWS code deploy part... (How I can send the generated .jar to S3) ?.
Hi @jrodriguez93 ,
For spring boot you can create the jar file zip it together with appspec.yml and scripts on bitbucket pipelines. I have worked on something close to that and that is how I approached and it works well.
Find attached some sample files for deploying to the EC2 server using bitbucket pipelines. This assumes that you have already configured AWS codedeploy to deploy to EC2 server. Please check them out Sample config files
Remember to add after_install.sh, application_start.sh, before_install.sh to execute actions before and after deployment.
I hope they can help. Let me know in case you have any questions.
I followed your sample config to deploy a maven based spring boot application to an EC2 instance successfully. However I am a little unsure of what to put in the BeforeInstall, AfterInstall, and ApplicationStart sections of the AppSpec file. I will like to execute the jar as a Linux service, start, and stop the service. Kindly help with sample config for this.
There's also a great tutorial of setting up a pipeline that uses AWS CodeDeploy.
I hope this helps. Let me know if you have any questions.
Hey Community! We’re willing to wager that quite a few of you not only use Bitbucket, but administer it too. Our team is excited to share that we’ll be releasing improvements throughout this month of...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events