Zen Cart Logo
Forums / General Questions / Configuring a new site on a local development box

Configuring a new site on a local development box

Views: 942

Results 1 to 5 of 5
30 Jul 2013, 6:09 PM
#1
markz avatar

markz

New Zenner

Join Date:
Feb 2013
Posts:
15
Plugin Contributions:
0

Configuring a new site on a local development box

It seems the popular protocol for installing a new website is to do it on a live server, but how does one go about installing and configuring a new site on a local development box before uploading it to a live server? Also, what are some pro's and con's? Not being able to test the site until it's live is one drawback that I can see, but what are some other's?

30 Jul 2013, 6:48 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Configuring a new site on a local development box

Some info here:

http://www.zen-cart.com/wiki/index.php/Making_a_Local_Copy

To me, the biggest drawback of a local installation is that you can't provide a link to forum members if you run into a problem you can't solve. It's almost always easier to troubleshoot an issue if you can see it live. I've never installed Zencart locally.

30 Jul 2013, 7:01 PM
#3
lhungil avatar

lhungil

Totally Zenned

Join Date:
Feb 2012
Location:
mostly harmless
Posts:
1,818
Plugin Contributions:
4

Re: Configuring a new site on a local development box

One can test without any major issues a "local test / development" server. The gotcha is one will need configure and secure whatever webserver stack (LAMP, WAMP, MAMP, etc) and other servers / services (such as email) are decided upon. To make sure everything works the same in both the "local" and "production" environments, the environments need to match as closely as possible. This usually means taking the time to verify the "local test / development" server is running with the same software, software versions, and settings (as the "production" server).

One of the main advantages to using a "remote test / development" server is less time spent configuring and securing the server environment. Creating a "remote test / development" server can be quickly accomplished by simply creating a "subdomain" on the production server (with a separate document root / public_html). You can then configure the "subdomain" to block everyone by default and only allow access to the website by specific IPs or a password.

The major advantage to working on a "local test / development" server is you can configure additional debugging tools, do no need to copy files to a remote environment to test, features not requiring internet access can be tested w/o internet access (when on the go), and of course you can test changes without impacting other people who may be looking at or working on the website or application. The downside is you need to stage to a "remote test / development" server for others to see the changes.

I tend to use a "local test" server for active development and debugging. I tend to use "remote test" server to share stable changes with other members of the development team and with clients.

Note: This is just a short and quick discussion (there are other options as well). Depending on the project (including requirements, scope, and other factors), one will want to do their own evaluation and risk assessment to determine how to best "test" websites and applications prior to release on a "production / live" server. No matter what method(s) are used to test a website or application, one will want to take precautions to mitigate the associated risks of data being lost, corrupted, and / or stolen.

31 Jul 2013, 10:00 AM
#4
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Re: Configuring a new site on a local development box

lhungil:

I tend to use a "local test" server for active development and debugging. I tend to use "remote test" server to share stable changes with other members of the development team and with clients..

Same here. In fact I don't see why anyone would do it any other way these days, especially when most (if not all) IDE's support and even 'encourage' this type of development environment.

Considering the number of people that (apparently) learn HTML using Dreamweaver (which has encouraged this type of environment for as long as I can remember) it is surprising how many folk still work on a live site.

Cheers
Rod

31 Jul 2013, 1:03 PM
#5
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,100
Plugin Contributions:
56

Re: Configuring a new site on a local development box

One additional thing you can do with your "local" site so that it's an almost-exact duplicate of your "remote" site is to make use of the /includes/local/configure.php and /YOUR_ADMIN/includes/local/configure.php files to contain your local configuration (just remember to never upload them, it's a guaranteed server 500 error!).

Zen Cart looks for those files specifically and, if present, loads them before the /includes/configure.php and /YOUR_ADMIN/includes/configure.php versions. You'll modify those versions of the files to reflect your local (in my case XAMPP) configuration.