summaryrefslogtreecommitdiff
path: root/setup-acf.in
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2016-11-02 22:28:23 +0100
committerJakub Jirutka <jakub@jirutka.cz>2016-11-02 23:12:27 +0100
commit281cbbd6cd8ecfc3d5c1a365ae01f2e49ad25f24 (patch)
tree9bf3e352b97c7d3742c94b31d7d2e6886dc001b1 /setup-acf.in
parent07c02f672a5708e4dcd9ed9aa3935840916f4c6e (diff)
downloadalpine-conf-281cbbd6cd8ecfc3d5c1a365ae01f2e49ad25f24.zip
indent heredocs and replace echos with heredoc where appropriate
Diffstat (limited to 'setup-acf.in')
-rw-r--r--setup-acf.in50
1 files changed, 25 insertions, 25 deletions
diff --git a/setup-acf.in b/setup-acf.in
index 46e3529..23ef687 100644
--- a/setup-acf.in
+++ b/setup-acf.in
@@ -62,22 +62,22 @@ if [ -f $PEMFILE ]; then
echo "$PEMFILE already exist."
else
mkdir -p $SSLDIR
-cat >$SSLCNF <<EOF
-[ req ]
-default_bits = 1024
-encrypt_key = yes
-distinguished_name = req_dn
-x509_extensions = cert_type
-prompt = no
-
-[ req_dn ]
-OU=HTTPS server
-CN=$(hostname -f || hostname)
-emailAddress=${EMAIL:-postmaster@example.com}
-
-[ cert_type ]
-nsCertType = server
-EOF
+ cat >$SSLCNF <<-__EOF__
+ [ req ]
+ default_bits = 1024
+ encrypt_key = yes
+ distinguished_name = req_dn
+ x509_extensions = cert_type
+ prompt = no
+
+ [ req_dn ]
+ OU=HTTPS server
+ CN=$(hostname -f || hostname)
+ emailAddress=${EMAIL:-postmaster@example.com}
+
+ [ cert_type ]
+ nsCertType = server
+ __EOF__
echo "Generating certificates for HTTPS..."
openssl genrsa 2048 > $KEYFILE
openssl req -new -x509 -nodes -sha1 -days 3650 -key $KEYFILE \
@@ -87,15 +87,15 @@ EOF
mv $CRTFILE $PEMFILE
fi
-cat >/etc/mini_httpd/mini_httpd.conf <<EOF
-nochroot
-dir=/var/www/localhost/htdocs
-user=nobody
-cgipat=cgi-bin**
-certfile=$PEMFILE
-port=443
-ssl
-EOF
+cat >/etc/mini_httpd/mini_httpd.conf <<-__EOF__
+ nochroot
+ dir=/var/www/localhost/htdocs
+ user=nobody
+ cgipat=cgi-bin**
+ certfile=$PEMFILE
+ port=443
+ ssl
+__EOF__
if [ -n "$address" ]; then
echo "host=$address" >> /etc/mini_httpd/mini_httpd.conf
fi