1
votes

I installed odoo 10 in centos 7 by this tutorial https://www.rosehosting.com/blog/install-odoo-10-on-centos-7-with-apache-as-a-reverse-proxy/

working well, I can access odoo by url ip:port, i.e (192.168.1.1:8069)

But the problem is, I'm using odoo 10 in VPS (Virtual private server with centos 7 as operating system),

how can i access odoo without ip address ? I want to access odoo by domain (like www.domain.com), Anyone can help me to do this?

I try this code, but does not works

<VirtualHost *:80>
ServerName joko.jubaedah.com
ServerAlias www.joko.jubaedah.com

ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>

ProxyPass / http://joko.jubaedah.com:8069
ProxyPassReverse / http://joko.jubaedah.com:8069
<Location />
Order allow,deny
Allow from all
</Location>
</VirtualHost>

I want access odoo by domain such as www.joko.jubaedah.com (using sub domain concept) or www.jubaedah.com/joko

Thanks in advance.

1

1 Answers

1
votes

Open odoo.conf by nano /etc/odoo/odoo.conf and change xmlrpc_port = 8069 to your port and restart by systemctl restart odoo.

And Configure Apache:

yum install httpd

Enable it to start on boot, then start Apache:

systemctl enable httpd

systemctl start httpd

Proxy configuration. Open a new config file for your domain:

nano /etc/httpd/conf.d/your_domain.conf

<VirtualHost *:80>
ServerName your_domain.com
ServerAlias www.your_domain.com

ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>

ProxyPass / http://your_domain.com:8069/
ProxyPassReverse / http://your_domain.com:8069/
<Location />
Order allow,deny
Allow from all
</Location>
</VirtualHost>

service httpd restart