Prerequisites
Ensure you have
- A backup of the web site folder
- A backup of the DB
- A PC with IIS, SQL server etc.
- Make sure that you have DNS-names pointing to localhost, for DNN, the convention is usually *.dnndev.me
Specs
[[Name of the site on your pc value=site.dnndev.me]]
Setup the local system (on your PC)
- DB
- Unzip the DB (both the MDF and LDF) to where you have local DBs, for example in c:\db\site-name
- Restore Datebase if you have a .bak file
- In SQL Manager, open the table PortalAlias and add the name you will use for local access
- Website
- Unzip the web site backup to where you run your local sites, for example in
c:\projects\site-name\website
- Configure IIS
- Run the folder with the web site, and configure it to use a local name, for example site-name.dnndev.me
- As application pool, select .NET v4.5 (or any newer version number)
- Add entry to hosts file
- In order to route requests to the domain to your local computer, you have to add a hosts-file entry.
- Navigate to C:\Windows\system32\drivers\etc and open the file "hosts" with Notepad++. Add the following line:
127.0.0.1 [websitename].dev
- Save the file; you will be asked to open Notepad++ in Administrator mode; click yes and save again
- Adjust the web.config of the site to access the local DB
- Check the connectionString SiteSqlServer Data Source