- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
SETTING UP A MAGENTO SITE ON LOCALHOST
Hi,
I am facing issue in porting our live code base to local host for development purpose and to test locally before uploading the changes on live server.
Magento version : 1.9.2.2 CE
Challenges i am facing are
1. live db is quite big having some 50k plus products so it is not feasible to dump the data on each developers pc, so we have hosted the db server on public ip machine for every developer to connect to that db by doing changes in app/etc/local.xml
UPDATE core_config_data SET value=”https://127.0.0.1/live/” WHERE path=”web/secure/base_url”;
RewriteCond %{SERVER_PORT} 80
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteCond %{REQUEST_URI} !^/\.well-known/pki-validation/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteRule ^(.*)$ https://127.0.0.1/live/$1 [R,L]
Not sure whether this is the correct way
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
Just to add i have deleted content in var/cache and var/session folder too
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
You do not need to setup the redirects as changing the Magento Base URL should suffice.
You may need to look around and see if there's anything else is causing the redirect to the live site, for example hardcoded links.
If you can't get this to work at worst case you may want to consider setting a host entry at your local computer to point the live domain to your local environment instead so you do not need to change the Base URL.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
Hi James,
Thanks for your reply, i will try to figure out any hard coded link if any.
I have one more doubt regarding working on magento , we have a team of 5 developers now once the live code base has been copied on local system we are maintaining the list of files that are changed locally and then only those files are replaced in the live code base.
But suppose if we add some attribute via admin panel how will i come to know which file has been modified since there is very less documentation about what magento does in the backend.
Regards
Kiran
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
I am not a developer so I may be wrong but I believe that you can either copy your dev environment to the live environment (and merge the other data like customer and order details) or you can document any changes you've made to the dev environment to be replicated at the live environment.
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
Hi James,
Thanks a lot for the guidance, actually i am quiet new to magento ie some of my doubts may be very basic one.
Regards
Kiran Bhushan
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: SETTING UP A MAGENTO SITE ON LOCALHOST
Connect to a central database server instead of hosting the database locally on each developer's machine. Modify the app/etc/local.xml file with the correct remote database server details for each developer's setup.
If you're redirected to the live site after porting, clear the cache, verify the core_config_data table values for web/unsecure/base_url and web/secure/base_url, and ensure the .htaccess file is properly configured.
If you can't access the admin panel, check the admin panel URL, file permissions, and consider clearing the admin session.