Last active
May 11, 2019 16:37
-
-
Save ep4sh/9437b97a86893985cb8c0d2beabc26f2 to your computer and use it in GitHub Desktop.
nginx sed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo yum install epel-release -y && sudo yum install nginx -y && \ | |
sudo sed -i 's/listen .* 80 .*/listen 8080 default_server;/' /etc/nginx/nginx.conf && \ | |
sudo sh -c "echo `curl -s http://169.254.169.254/latest/meta-data/public-ipv4` > /usr/share/nginx/html/index.html" && \ | |
sudo systemctl restart nginx |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment