Sha256: 0ba921672d2545debbe7c681256dbe51f406fa6675b7d4ce5da814d6c4c4c46c

Contents?: true

Size: 1.37 KB

Versions: 19

Compression:

Stored size: 1.37 KB

Contents

#!/bin/sh

#    This file is part of EC2 on Rails.
#    http://rubyforge.org/projects/ec2onrails/
#
#    Copyright 2007 Paul Dowman, http://pauldowman.com/
#
#    EC2 on Rails is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    EC2 on Rails is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.


# Generate a new self-signed cert and key for https

echo "Generating default self-signed SSL cert and key..."

export RANDFILE=/tmp/randfile

cd /tmp
openssl genrsa -out server.key 1024
openssl req -new -key server.key -out server.csr <<END
CA
.
.
.
.
.
.
.
.

END
openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt

mkdir -p /etc/ec2onrails/ssl/cert
mkdir -p -m 700 /etc/ec2onrails/ssl/private
mv server.key /etc/ec2onrails/ssl/private/ec2onrails-default.key
mv server.crt /etc/ec2onrails/ssl/cert/ec2onrails-default.crt
rm $RANDFILE
rm server.csr

Version data entries

19 entries across 19 versions & 11 rubygems

Version Path
Agiley-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
ScholarNexus-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
ScholarNexus-ec2onrails-0.9.11 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
arpitjain11-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
ewoutvonk-ec2onrails-0.9.10.4.001 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
gigpark-ec2onrails-0.9.10.3 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
hennk-ec2onrails-0.9.9.1 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
hennk-hennk-ec2onrails-0.9.9.2 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
hennk-hennk-ec2onrails-0.9.9.3 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
mdh-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
pauldowman-ec2onrails-0.9.10.0 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
pauldowman-ec2onrails-0.9.10.1 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
pauldowman-ec2onrails-0.9.10.2 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
pauldowman-ec2onrails-0.9.10.3 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
pauldowman-ec2onrails-0.9.10.4 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key
pauldowman-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
rsanheim-ec2onrails-0.9.11.1 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
skippy-ec2onrails-0.9.10 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh
skippy-ec2onrails-0.9.11 server/files/usr/local/ec2onrails/startup-scripts/first-startup/generate-default-web-cert-and-key.sh