SpringBoot 2.5.3 does not work on AWS Elastic Beanstalk - amazon-web-services

I'm attempting to upgrade SpringBoot from v2.4.0 to 2.5.3.
My Boot project installs and runs fine locally with both versions.
Version 2.4.0 works fine on Beanstalk. When updating to 2.5.3 however, nginx returns a 301 for all requests to the Boot application. I am testing on the same instance (so same config) on Corretto 11 running on 64bit Amazon Linux 2/3.2.7.
The SpringBoot logs are identical between the 2 when starting up on both local and SpringBoot minus a few verbiage changes. No other changes exist in the code.
I'm a bit stuck. I've reviewed the Java logs, nginx, Beanstalk init logs, and everything looks fine.
Edit I am looking for suggestions on troubleshooting next steps for AWS Beanstalk SpringBoot apps as the 2 version produce identical EB and app logs, and I am not sure where else I should be looking.

Related

Why Elastic beanstalk restore to old version

why Elastic beanstalk restore to old version in AWS.
i try to deploy simple leraval project to aws.
Elastic Beanstalk is a service that makes it easy to deploy, run, and scale web applications and services on the Amazon Web Services (AWS) platform. When you deploy your application to Elastic Beanstalk, it creates an environment for your application and manages the details of the infrastructure and application components for you.
In some cases, Elastic Beanstalk may automatically restore your application to a previous version if it detects that the new version you are deploying is not working correctly. This can happen if the new version is not compatible with the environment or if it is causing errors. Restoring to a previous version can help prevent downtime or other issues with your application.
It is important to carefully test your application before deploying it to Elastic Beanstalk, to ensure that it is compatible with the environment and will run smoothly. This can help prevent issues like an automatic restoration to a previous version

Docker container runs local, but not on AWS Elastic BeanStalk

I created Docker container with flash and gunicorn. I tested it locally successfully and pushed it without any problems to Docker hub. I also have AWS EB CLI installed so I tested it with eb local run. Everything worked fine.
I used the following link to deploy it on AWS Elastic BeanStalk. When I visit URL of the application, I am getting HTTP ERROR 504. I looked at log file and there are any error messages.
How can I further troubleshoot this issue?

How to automatically deploy asp.net core application to ec2 instance using jenkins?

I have hosted an ASP.NET Core web application on an EC2 instance using Nginx. The EC2 isntance is running on Ubuntu Server 16.04 LTS machine.
I am developing the code in windows machine and publishing the code. Then copying the files into the EC2 instance using WinSCP. The web application is running nicely and i can hit the application using postman or browser.
Now, i have decided to use jenkins for CI/CD. I have installed jenkins in the same ec2 server where my web application running. Jenkins is running in port 8080 and my web application is running in port 80. I have configured jenkins with my bitbucket repository by following this link.
Now, my jenkins server is up and running. If i commit anything in the bitbucket repository, jenkins server automatically triggers a build.
Previously, i have published the code using below command:
dotnet publish -o my-sample-site
And then copied the files from my-sample-site directory to the directory in EC2 instance. Now, i want to automatically build the asp.net core web source codes and publish the codes to the folder where my web application is running. I may have to restart the service also after changing the codes.
What should i include in the jenkins build step so that whenever bitbucket repository changes triggers build in jenkins, it will build the asp.net core source codes and then publish the codes in the directory of the EC2 instance where my web application is running.
How should i do this automatically? Any reference please. Thanks in advance.
I have set up CI/CD server using Jenkins connected to a Bitbucket repository for an ASP.NET Core Web API running in an EC2 instance. Anyone can check my article here.

Deploying a web application for Selenium testing on AWS EC2

I have a web application that uses Selenium in backend to run few scripts when invoked by user. I want to deploy this web app on AWS.
Here are my findings so far:
I can have a windows EC2 instance created and then I can install tomcat, firefox and all the necessary stuff. Then using putty or any other client, I can deploy my war and start tomcat.
I can directly make use of Elastic Beanstalk and deploy my war file there itself but then, there is no windows EC2 available for beanstalk and I don't know how to install firefox there and make my application work.
What is the best way to achieve this and what steps should I follow. I want to install a specific firefox version to be able to make it run with my selenium scripts.
There are two separate things here:
Deployment of web application on AWS cloud
Run the selenium tests against your web application
According to me, you should first think of deploying a web application to AWS cloud. There are many ways by which you can get it deployed to AWS cloud with below services:
Spin a new AWS EC2 instance, install all required software and deploy the web application.
Use AWS elastic beanstalk service with either with tomcat or docker.
Use AWS ECS if you prefer docker
According to me, second option will be quick for you with tomcat environment option. If you select tomcat environment, then your platform will be Tomcat 8 Java 8 on 64bit Amazon Linux.
Now, here comes the second part. You can have below options for your browser environments.
Spin a new separate AWS EC2 instances with correct AMI and install your specific browsers on these instances.
If you prefer SaaS, then you can take a look at browserstack or SauceLabs for remote environment.
If you have CI(jenkins/travis/Circle CI), then make use of that infrastructure to luanch your tests with either option from the above.

Deploying Ruby on rails applications using GIT in AWS elastic beanstalk

I am looking at ways to have a setup for complete development and deployment cycle by using Git to have code versions and then transfer a that code(push) into an AWS elastic Beanstalk instance... I would also like to know of any other methods that includes 'rubber' setup. can you please guide me in this regard.
As of November 1, 2012, Elastic Beanstalk now natively supports Rails and Sinatra apps running Ruby 1.8.7 or 1.9.3. Phusion Passenger is the application server. Git deployment is included, and the EB command line tools have been updated.
Here is the announcement:
Here is a good tutorial