Created
May 21, 2015 22:01
-
-
Save joescii/9de5896f16ae6d6edd7c to your computer and use it in GitHub Desktop.
No ssh in rhel AMI created by Packer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -eux | |
sudo mv /tmp/symg /opt/symg | |
sudo echo "java -Dsymbol.generator.localhost=false -jar /opt/symg/symbol-generator.jar" >> /etc/rc.d/rc.local |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash -eux | |
# Install Java 7 | |
sudo rpm -Uvh /tmp/jdk-linux-x64.rpm | |
rm -f /tmp/jdk-linux-x64.* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"variables": { | |
"aws_access_key": null, | |
"aws_secret_key": null, | |
"source_ami": null, | |
"region": null, | |
"vpc_id": null, | |
"subnet_id": null, | |
"security_group_id": null, | |
"timestamp": null, | |
"svn_id": "n/a", | |
"ahp_id": "n/a", | |
"project_root": "n/a" | |
}, | |
"builders": [ | |
{ | |
"type": "amazon-ebs", | |
"region": "{{ user `region` }}", | |
"source_ami": "{{ user `source_ami` }}", | |
"instance_type": "t1.micro", | |
"ssh_username": "root", | |
"associate_public_ip_address": "true", | |
"access_key": "{{ user `aws_access_key` }}", | |
"secret_key": "{{ user `aws_secret_key` }}", | |
"vpc_id": "{{ user `vpc_id` }}", | |
"subnet_id": "{{ user `subnet_id` }}", | |
"security_group_id": "{{ user `security_group_id` }}", | |
"ami_name": "ami-exp-symg-{{user `timestamp`}}", | |
"tags": { | |
"Name": "ami-exp-symg", | |
"Timestamp": "{{user `timestamp`}}", | |
"SVN Revision": "{{user `svn_id`}}", | |
"AHP Build Life": "{{user `ahp_id`}}", | |
"AHP URL": "http://wv-ahpserver.wv.mentorg.com:8080/tasks/project/BuildLifeTasks/viewBuildLife?buildLifeId={{user `ahp_id`}}" | |
} | |
} | |
], | |
"provisioners": [ | |
{ | |
"type": "file", | |
"source": "{{user `project_root`}}/dependencies/java/jdk-linux-x64.rpm", | |
"destination": "/tmp/jdk-linux-x64.rpm" | |
}, | |
{ | |
"type": "shell", | |
"script": "java.sh" | |
}, | |
{ | |
"type": "file", | |
"source": "./deploy/", | |
"destination": "/tmp/symg" | |
}, | |
{ | |
"type": "shell", | |
"script": "install.sh" | |
} | |
] | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"source_ami": "ami-c4aeb581", | |
"region": "us-west-1", | |
"vpc_id": "vpc-11817574", | |
"subnet_id": "subnet-be1e19f8", | |
"security_group_id": "sg-e27ac187" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment