a travis script, since its getting a little complex
This commit is contained in:
@@ -3,11 +3,7 @@ script: cd tests && ./run_ec2 test
|
|||||||
before_install:
|
before_install:
|
||||||
- "sudo apt-get install -y ec2-api-tools"
|
- "sudo apt-get install -y ec2-api-tools"
|
||||||
- "sudo apt-get install -y s3cmd"
|
- "sudo apt-get install -y s3cmd"
|
||||||
- "sed --in-place \"s/access_key/access_key = $AWS_ACCESS_KEY/\" .s3cfg"
|
- "tests/setup_travis"
|
||||||
- "sed --in-place \"s|secret_key|secret_key = $AWS_SECRET_KEY|\" .s3cfg"
|
|
||||||
- "s3cmd -c .s3cfg get s3://progrium-private/ec2_cert.pem /tmp/cert"
|
|
||||||
- "s3cmd -c .s3cfg get s3://progrium-private/ec2_pk.pem /tmp/pk"
|
|
||||||
- "mkdir -p ~/.ssh && s3cmd -c .s3cfg get s3://progrium-private/test.pem ~/.ssh/id_rsa && chmod 600 ~/.ssh/id_rsa"
|
|
||||||
env:
|
env:
|
||||||
global:
|
global:
|
||||||
- EC2_CERT=/tmp/cert
|
- EC2_CERT=/tmp/cert
|
||||||
|
|||||||
@@ -35,8 +35,8 @@ done
|
|||||||
echo "-----> Connecting and running boostrap script..."
|
echo "-----> Connecting and running boostrap script..."
|
||||||
cat ../bootstrap.sh | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "HOSTNAME=$PUBLIC_IP sudo bash" 2>&1 | indent
|
cat ../bootstrap.sh | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "HOSTNAME=$PUBLIC_IP sudo bash" 2>&1 | indent
|
||||||
echo "-----> Installing SSH public keys..."
|
echo "-----> Installing SSH public keys..."
|
||||||
ssh-add -L | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "sudo gitreceive upload-key test" > /dev/null
|
cat ~/.ssh/id_rsa.pub | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "sudo gitreceive upload-key test" > /dev/null
|
||||||
ssh-add -L | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "sudo sshcommand acl-add dokku test" > /dev/null
|
cat ~/.ssh/id_rsa.pub | ssh -o "StrictHostKeyChecking=no" ubuntu@$PUBLIC_IP "sudo sshcommand acl-add dokku test" > /dev/null
|
||||||
for app_path in apps/*; do
|
for app_path in apps/*; do
|
||||||
app=$(basename $app_path)
|
app=$(basename $app_path)
|
||||||
echo "-----> Running test deploy of $app..."
|
echo "-----> Running test deploy of $app..."
|
||||||
|
|||||||
9
tests/setup_travis
Executable file
9
tests/setup_travis
Executable file
@@ -0,0 +1,9 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
sed --in-place "s|access_key|access_key = $AWS_ACCESS_KEY|" .s3cfg
|
||||||
|
sed --in-place "s|secret_key|secret_key = $AWS_SECRET_KEY|" .s3cfg
|
||||||
|
s3cmd -c .s3cfg get s3://progrium-private/ec2_cert.pem /tmp/cert
|
||||||
|
s3cmd -c .s3cfg get s3://progrium-private/ec2_pk.pem /tmp/pk
|
||||||
|
mkdir -p ~/.ssh
|
||||||
|
s3cmd -c .s3cfg get s3://progrium-private/test.pem ~/.ssh/id_rsa
|
||||||
|
chmod 600 ~/.ssh/id_rsa
|
||||||
|
openssl rsa -in ~/.ssh/id_rsa -pubout > ~/.ssh/id_rsa.pub
|
||||||
Reference in New Issue
Block a user