klas.wirholm
klas.wirholm

I had som problems getting more than one October installation to function in backend, got wrong security tokens a lot, especially when more than one October backend was open. So you need domain ore subdomain, for more than one October installation, what I understand.

Well, my goal is also that I can both develop on local host and test site on local network (for responsive testing, mobile phones).

Configuration functions good on local host, but when I go to local ip, one installation of October takes over. It even takes over root (i.e my Ip: 192.168.0.MYIP). (for security reason I hade change my ip number in this post to MYIP)

Here's my configuration.

IN: /etc/hosts

127.0.0.1 localhost localhost.local freepower.local

127.0.0.1 october.localhost october.local

127.0.0.1 october2.localhost october2.local

: 1 localhost localhost.local freepower.local

fe80::1%lo0 localhost

192.168.0.MYIP freepower.local freepower

192.168.0.MYIP october.local

192.168.0.MYIP october2.local

255.255.255.255 broadcasthost

IN Apache config: /Applications/MAMP/conf/apache/extra/httpd-vhosts.conf

<VirtualHost *:80>

DocumentRoot "/Users/klas/web/october"

ServerName october.localhost

ServerAlias october.local

</VirtualHost>

<VirtualHost *:80> DocumentRoot "/Users/klas/web/october2"

ServerName october2.localhost

ServerAlias october2.local

</VirtualHost>

<VirtualHost 192.168.0.106:80>

DocumentRoot "/Users/klas/web"

ServerName freepower.local

</VirtualHost>

<VirtualHost *:80>

DocumentRoot "/Users/klas/web"

ServerName localhost

</VirtualHost>

<VirtualHost *:80>

DocumentRoot "/Users/klas/web"

ServerName localhost.local

</VirtualHost>

<VirtualHost *:80>

DocumentRoot "/Users/klas/web"

ServerName freepower.local

</VirtualHost>

Last updated

klas.wirholm
klas.wirholm

I figured out, had to add Virtual host for ip on local network, also. Added last IN Apache config: /Applications/MAMP/conf/apache/extra/httpd-vhosts.conf:

<VirtualHost *:80>

DocumentRoot "/Users/klas/web"

ServerName 192.168.0.MYIP

</VirtualHost>

Great forum, I got a lot of help here ... from my self! ;) Jokes aside, I hope it help some one else.

My configuration now make it posible to access October on:

October CMS one:

october.localhost (on my computer)

localhost/october (on my computer)

october.local (on network, with right config of hosts on other machines)

192.168.0.MYIP/october

October CMS two:

october2.localhost (on my computer)

localhost/october2 (on my computer)

october2.local (on network, with right config of hosts on other machines)

192.168.0.MYIP/october2

I work on backend on october.local / october2.local I also had to remove (actually hashed it out) RewriteBase in each October htaccess file, to get this to function.

As long as url:s (to images and so on) are relative ore by twig, every thing seems to function good!

Last updated

1-2 of 2