From c6fb97207d3bf190ca402fdf5eb54ab3b1b884a7 Mon Sep 17 00:00:00 2001 From: Mohamed Sdeek Date: Wed, 20 Mar 2019 23:39:43 +0200 Subject: [PATCH] Update odoo_install.sh --- odoo_install.sh | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/odoo_install.sh b/odoo_install.sh index 1cd0ff4..2700d09 100644 --- a/odoo_install.sh +++ b/odoo_install.sh @@ -58,6 +58,42 @@ sudo apt-get install libpng12-0 sudo apt install -y libxslt1-dev git python3-pip build-essential wget python3-dev python3-venv python3-wheel libxslt-dev libzip-dev libldap2-dev libsasl2-dev python3-setuptools node-less sudo apt-get -y install python3-dev libmysqlclient-dev libxmlsec1-dev +#---------------------------------------------------------- +# install apache server and config proxy +#---------------------------------------------------------- +echo -e "\n---- install apache server and config proxy ----" +sudo apt install apache2 +sudo ufw allow 'Apache' +sudo systemctl status apache2 +a2enmod proxy +a2enmod proxy_http +sudo touch /etc/apache2/sites-available/codefish.com.eg.conf +sudo su root -c "printf'' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ServerName codefish.com.eg' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ServerAlias *.codefish.com.eg' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf'' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ProxyRequests Off' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' Order deny,allow' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' Allow from all' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf'' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ProxyPass / http://localhost:8069/' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ProxyPassReverse / http://localhost:8069/' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ProxyPass /longpolling/ http://localhost:8072/' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ProxyPassReverse /longpolling/ http://localhost:8072/' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf'' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' Order allow,deny' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' Allow from all] >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf' ' >> /etc/apache2/sites-available/codefish.com.eg.conf" +sudo su root -c "printf'' >> /etc/apache2/sites-available/codefish.com.eg.conf" + +ln -s /etc/apache2/sites-available/codefish.com.eg.conf /etc/apache2/sites-enabled/codefish.com.eg.conf +service apache2 restart + + + #-------------------------------------------------- # Install PostgreSQL Server #--------------------------------------------------