summaryrefslogtreecommitdiff
path: root/.makecert.exp
diff options
context:
space:
mode:
authorB Stack <bgstack15@gmail.com>2016-10-20 16:15:23 -0400
committerB Stack <bgstack15@gmail.com>2016-10-20 16:15:23 -0400
commitd60ed67fa4eeeba312646358316e49c0a6cbc6f6 (patch)
tree7cec285c82c1e15cc021086899165afb7bed2385 /.makecert.exp
downloaddeployscripts-d60ed67fa4eeeba312646358316e49c0a6cbc6f6.tar.gz
deployscripts-d60ed67fa4eeeba312646358316e49c0a6cbc6f6.tar.bz2
deployscripts-d60ed67fa4eeeba312646358316e49c0a6cbc6f6.zip
initial commit
Diffstat (limited to '.makecert.exp')
-rwxr-xr-x.makecert.exp22
1 files changed, 22 insertions, 0 deletions
diff --git a/.makecert.exp b/.makecert.exp
new file mode 100755
index 0000000..36bdee1
--- /dev/null
+++ b/.makecert.exp
@@ -0,0 +1,22 @@
+#!/usr/bin/expect
+set keyfile [lindex $argv 1]
+set certfile [lindex $argv 2]
+set timeout 2
+spawn openssl req -x509 -nodes -days 1095 -newkey rsa:2048 -keyout "${keyfile}" -out "${certfile}"
+expect "Country Name (2 letter code) \[XX\]:"
+set timeout 1
+send "US\r"
+expect "State or Province Name (full name) \[\]:"
+send "Some State\r"
+expect "Locality Name (eg, city) \[Default City\]:"
+send "Default City\r"
+expect "Organization Name (eg, company) \[Default Company Ltd\]:"
+send "Default Company Ltd\r"
+expect "Organizational Unit Name (eg, section) \[\]:" &&
+send "Information Technologies\r"
+expect "Common Name (eg, your name or your server's hostname) \[\]:"
+send [lindex $argv 0]
+send "\r"
+expect "Email Address \[\]:"
+send "linuxadmin@example.com\r"
+interact
bgstack15