Skip to content

Instantly share code, notes, and snippets.

@yustam
Created May 2, 2014
Embed
What would you like to do?
Install oracle jdk7 on Amazon ElasticBeanstalk
files:
"/home/ec2-user/install-oracle-jdk.sh":
mode: "000755"
owner: ec2-user
group: ec2-user
content: |
#!/usr/bin/env bash
wget -O jdk-7u25-linux-x64.rpm --no-cookies --no-check-certificate --header 'Cookie:gpw_e24=http://www.oracle.com; oraclelicense=accept-securebackup-cookie' 'http://download.oracle.com/otn-pub/java/jdk/7u51-b13/jdk-7u51-linux-x64.rpm'
rpm -Uvh /home/ec2-user/jdk-7u25-linux-x64.rpm
alternatives --install /usr/bin/java java /usr/java/default/bin/java 3
alternatives --set java /usr/java/default/bin/java
commands:
execute-install-oracle-jdk-script:
command: ./install-oracle-jdk.sh
cwd: /home/ec2-user
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment