Development Sites

I like to develop locally on a VM through Vagrant. This means my cart's storefront url is something like "cscart.dev". If I try to share my work through something like localtunnel or forwarding my VM's port 80 to 8080, I just get the "store closed" graphic unless I'm accessing the site from its storefront URL.

Any workaround here?

Hello.

Usually it means that it is necessary to correct storefront URL in config.local.php file and admin.php?dispatch=companies.manage page.

Sincerely yours,
CS-Market.

Yes, I am trying to get the site to resolve for more than one location. More details:

I develop locally, my hosts file has an entry:

cscart.dev 192.168.2.2 192.168.2.2 ### cscart.dev resolves to an IP that only exists on my machine

If I run something like localtunnel, I get an address like this:

https://gqgh.localtunnel.me

Which you can then tell your client / coworker and they can view your work. So is it possible to have the same store resolve to multiple URLs.

Unfortunately, you have to set up new storefront name in the config.local.php and database. I'm not sure that it works, but possible workaround: try to set up Nginx as a reverse proxy before your application server (apache, probably) and transfer the 'Host' header as a 'cscart.dev'. It should looks like this:

{code}
upstream cscart-upstream {
    server [...];
}

server {
listen 80;
server_name _;

[...]

location / {
    proxy_pass http://cscart-upstream;
    proxy_set_header Host 'cscart.dev';
    [...]
}

}
{code}