17 votes

Nant backup and restore

** This is highly Beta **

This Project is just a nant build that you can use to archive instances of Umbraco to a zip file and then restore them to a new instance. (An instance consists of an IIS site, and a database)

If you find errors please report/fix them so we can improve this for everyone.

This has been tested on:

  • Windows 7 ultimate
  • IIS 7.5
  • SQL Server 2008 R2

It won't work with non IIS/SQL setup.

Requirements to run:

  • Nant - Tested with 0.9.0
  • NAnt.Contrib.Tasks.dll

Before running confiure the following in your build script:

  • web.root - a folder where you keep you IIS sites
  • windows.path - c:\windows etc
  • sql.data.dir - path to put SQL server data and log files.
  • contrib.assembly - path to NAnt.Contrib.Tasks.dll
  • ole.db - OLEDB provider connection to your database

To backup:

  • nant backup -D:umb.src=d:\www\4.7 -D:zip.file=umb4.7.clean.zip

To Restore

  • nant restore -D:zip.file=umb4.7.clean.zip -D:target.name=targetsite

Backup performs the following operations:

  • Stop IIS
  • Copy files to temp folder
  • Backup database to temp foler
  • Zip files including www root and db backup
  • start iis

Restore performs the following operations:

  • Stop IIS
  • Create folder for new website - $(web.root}/${target.name}
  • Create new IIS site with .net 4 App Pool - both named ${target.name}
  • Crate new database and login - dbname, login, password all equal ${target.name}
  • Add a host entry ${target.name}.local
  • Update connection string in new site web.config
  • Start IIS

 

 

Package files

Archived files

Documentation

No current release

Package owner

Darren Ferguson

Darren Ferguson

Darren has 3249 karma points

Package Compatibility

This package is compatible with the following versions as reported by community members who have downloaded this package:
Untested or doesn't work on Umbraco Cloud
8.0.x (untested)
7.14.x (untested)
7.13.x (untested)
7.12.x (untested)
7.11.x (untested)
7.10.x (untested)
7.9.x (untested)
7.8.x (untested)
7.7.x (untested)
7.6.x (untested)
7.5.x (untested)
7.4.x (untested)
7.3.x (untested)
7.2.x (untested)
7.1.x (untested)
7.0.x (untested)
6.1.x (untested)
6.0.x (untested)

You must login before you can report on package compatibility.

Package Information

  • Package owner: Darren Ferguson
  • Created: 13/05/2011
  • Current version 0.1
  • License MIT
  • Downloads: 1158