Unfold - 基于Powershell的. net web应用程序的部署解决方案

网友投稿 703 2022-10-26

Unfold - 基于Powershell的. net web应用程序的部署解决方案

Unfold - 基于Powershell的. net web应用程序的部署解决方案

Unfold

Unfold is a complete deployment solution for - based web applications. It gives you the ability to easily create and customize your deployment scenario's without having to resort to complex tools that are hard to automate or difficult to setup. Unfold is only powershell, so there's very little magic going on under the hood.

Check Getting Started wiki page for installation instructions and a quickstart

For updates and info, please check my blog

An introductionA full explanation of the deployment tasksAn example extension: minifying css and javascriptHow unfold handles rollbackConfiguring local builds

Example

The code snippet below is the entire deployment script for RaccoonBlog, the blogging engine behind Ayende's blog.

## A deployment example for RaccoonBlog, the blog engine that's powering## blogs like Ayende's# ConfigurationSet-Config project "raccoonblog"Set-Config scm gitSet-Config repository "https://github.com/fitzchak/RaccoonBlog.git"# Environment to use when not specifiedSet-Config default devSet-Config msbuild @('.\code\RaccoonBlog.Web\RaccoonBlog.Web.csproj')# For custom apppool nameSet-Config apppool "raccoonblog"# EnvironmentsSet-Environment dev { Set-Config basePath "c:\inetpub\wwwroot\raccoon" # machine to deploy to Set-Config machine "localhost"}Set-Environment staging { Set-Config basePath "d:\sites\raccoon" Set-Config machine "122.123.124.125" # ip address where WinRM is configured}# TasksImport-DefaultTasks# Set deploy as default tasktask Default -depends "deploy"

Executing a deployment is now simply a matter of executing the following PowerShell command in the folder where your deployment script resides

.\unfold.ps1 deploy -to staging

Features

Can deploy to both local and remote machines Deployments are based on what's in source control (git, svn) not what's in your working copy Rollback Deployment flow can be extended and/or customized through task hooks in order to allow advanced scenarios likesetting up a static website to server your images, js and cssmigrating the databasemodifying Web.config or other configuration files

Dependencies

There's nothing extra you need to install. Everything comes out-of-the-box.

Unfold depends on the following technologies. They are included in the installation.

For task configuration we depend on psakeFor access to remote machines we used powershell remoting, the SSH for windows. Check the wikifor instructions on how to set this up on the deployment target.

TODO

hg support, and other scmsnative support for database migration runners like FluentMigrator, DbUp or Entity Framework Migrationssupport for deploying to multiple machines. At the moment there can be only one target.Create-AssemblyInfo function for generating a shared assembmy info. Based on this

版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。

上一篇:在Mybatis中使用连表查询的一次实际应用
下一篇:yyeTs-resource-crawler 此程序可爬取大部分人人影视数据
相关文章

 发表评论

暂时没有评论,来抢沙发吧~