以前紹介したNATインスタンス構築の記事「CloutInitでNATインスタンス(iptables)を構築」に続き、 Webサーバ(Apache)の構築も試してみました。 初期構築スクリプトは下記となります。 #!/bin/sh set -e trap 'echo "NG: $?"' ERR yum -y install httpd mod_extract_forwarded if [ ! -L /etc/httpd/conf/httpd.conf ]; then mv /etc/httpd/conf/httpd.conf /etc/httpd/conf/httpd.conf.org ln -s /opt/suz-lab/etc/apache/httpd.conf /etc/httpd/conf/httpd.conf fi if [ ! -f /etc/httpd/conf/virtual