Refer this youtube video link
https://www.youtube.com/playlist?list=PLSg8jHkYTg9FG9v5VEikhYwhT_9SdXHcU
- Go to AWS Console
- In the right corner select the region => Mumbai asia pacific
- In the search, "EC2" => launch instances => Give name to vm
- Select Free AWS linux
- Amazon Machine Image (AMI) Free tire eligible
- Create new key pair => this will generate "privatekey file" .pem file
- Firewll general security group => new or existing
- Configuration storage
- Summary number of instances =>1 instance type t2.micro (free)
Finally created on launch instance
- select EC2 instance => select security tab => select security group = > edit inbound rules => select Type => custom TCP => Port range "8080" => Source => 0.0.0.0/0 => save rules
Search "Puttygen" in windows search start puttygen Generate "ppk file" using ".pem" file generated from EC2 instance click on save "private key" button
add host Name => EC2 instance => pubilc ip address => 13.232.254.239 Connection => SSH => Auth => Credentials => private key file => add ".ppk" file open Enter user name => ec2-user hit cmd => ls -l
File protocol => SFTP Host name => 13.232.254.239 port no => 22 user name = > EC2 instance password => ******
then Click on Adavance => SSH => Authentication => browse private key ok Press "Login"
On the Left side "Local Folders" or the right side "/home/ec2-user" Select jar from local that moved to "/home/ec2-user"
cmd => ls -l
Check jar file is displayed or not Once jar file displayed
Run jar file => java -jar "jar-name"
Then => java not found
To install java => sudo yum install java To check java version =>java -version
then execute => java -jar "jar-name"
To install java => sudo yum install java java -version