Skip to content

Instantly share code, notes, and snippets.

@geoffreysmith
Last active December 17, 2015 03:38
Show Gist options
  • Save geoffreysmith/5544474 to your computer and use it in GitHub Desktop.
Save geoffreysmith/5544474 to your computer and use it in GitHub Desktop.
Automated Sitecore installation in Dropkick
public class TheDeployment : Deployment<TheDeployment, DeploymentSettings>
{
public TheDeployment()
{
Define(settings => DeploymentStepsFor(SitecoreInstallation, s =>
{
s.UnzipArchive(settings.SitecoreArchivePath).To(settings.SitecoreExtractPath).DeleteDestinationBeforeDeploying();
s.CopyDirectory(settings.SitecoreExtractPath + @"Sitecore 6.6.0 rev. 130404\Website\").To(settings.WebsitePath).ClearDestinationBeforeDeploying();
s.RoundhousE()
.WithRoundhousEMode(RoundhousEMode.Restore)
.ForEnvironment(settings.Environment)
.OnDatabase(settings.WebDatabaseName)
.WithRestorePath(settings.WebDatabaseRestorePath);
s.RoundhousE()
.WithRoundhousEMode(RoundhousEMode.Restore)
.ForEnvironment(settings.Environment)
.OnDatabase(settings.CoreDatabaseName)
.WithRestorePath(settings.CoreDatabaseRestorePath);
s.RoundhousE()
.WithRoundhousEMode(RoundhousEMode.Restore)
.ForEnvironment(settings.Environment)
.OnDatabase(settings.MasterDatabaseName)
.WithRestorePath(settings.MasterDatabaseRestorePath);
s.CopyFile(@".\licences.xml").ToDirectory(settings.DatafolderPath);
s.Iis7Site(settings.VirtualDirectorySite)
.VirtualDirectory(settings.VirtualDirectoryName)
.SetAppPoolTo(settings.AppPoolName, pool => pool.SetRuntimeToV4()).SetPathTo(settings.WebsitePath);
}));
}
public static Role SitecoreInstallation { get; set; }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment