7

I want to automate applications/roles/features deployment (unattended) on Windows 2012 R2 Infrastructure, this project needs many hours of programming, this is why i'm asking here.

I want to deploy the following applications and roles : Active Directory, DNS, Sql Server 2012, Citrix XenApp Server, Citrix XenDesktop server, Citrix Datacollector, Citrix Licence server, Citrix Storefront server.

So the basic deployment will be on 8 servers (already installed on ESXi, with ip configuration only).

I imagined this scenario :

I will fill a CSV file that contains all of information, and execute Powershell scripts to deploy everything, we can imagine 1 script that will call different scripts for each components (sql, ad, dns, citrix etc..)

I don't want to depend of any tool (sccm, puppet or whatever..), this is the reasons why i want to create it from scratch -> But maybe i'm wrong.

I also read that there is a new feature called Powershell DSC, to simplify application deployment http://blogs.technet.com/b/privatecloud/archive/2013/08/30/introducing-powershell-desired-state-configuration-dsc.aspx There is a simple example : if you need 4 iis webserver then, execute this code :

Configuration DeployWebServers
{

    Node ("test1.domain.com","test2.domain.com","test3.domain.com","test4.domain.com")
    {
    Windows-Feature IIS
    {
         Name = "Web-Server"
         Ensure = "Present"
    }

    }
}

DeployWebServers -OutputPath "C:\scripts"
Start-DscConfiguration -path "C:\scripts" -Verbose -Wait -Force

But in my case i'll have only 1 server per application/roles or feature, if i understand well, this feature is interesting only if you need to deploy the same configuration on (x) servers

What's your advice? Should i choose to write powershell script from scratch? Or choose a solution like puppet or chef (much easier), but in this case i'll be dependant of a tool.

The best solution would be to use a sql database -> The final goal of my project is a web application with a database who will execute my powershell scripts to deploy my infrastructure

Of course from this web application, I will populate my database through forms, and my powershell scripts will query this database to get informations (ip address, client name, domain name, password, users...)**

Thank you for your advice.

Adeel ASIF
  • 2,924
  • 9
  • 24
  • 41
  • 1
    You write that you have "read that there is a new feature called Powershell DSC", but you don't really say much about why you are not using it in your current thought process. If you write this kind of configuration today, I'd probably suggest using DSC. It is actually rather unclear what your exact question is, what you have already tried, what you find yourself having problems with, etc, which makes it harder to help. But my suggestion would be having a look at DSC, since that is actually pretty much exactly what you want (except that it doesn't use csv-files). – Robert Westerlund Jun 18 '14 at 15:23
  • 1
    I do suggest you read more about PowerShell DSC, since there is a lot more to it than you suggest in your question. – Robert Westerlund Jun 18 '14 at 15:41
  • If you just want to deploy once your 8 servers with one role on each you should do it by hand ! – JPBlanc Jun 21 '14 at 16:15
  • @JPBlanc It was my idea also.. I would like to develop a frontend for my scripts, do you have any idea about it ? – Adeel ASIF Jun 24 '14 at 07:23
  • You can write front-ends to your powershell scripts using 'PowerShell Studio' by Sapien Technology. I love it. – Bill Jun 24 '14 at 19:43

2 Answers2

2

Chef or Puppet will be the easiest way forward and both tools have been around for long enough for you not to worry about them disappearing off the internents. Both work, pretty much, out of the box and will get you up and running in a considerably lesser time than if you were to design your own system.

Having said that, a benefit of going with a PS solution is it doesn't require any agents installed on destination boxes(connectivity thanks to WinRM). Ultimately you can wrap it up as a Powershell module, hand it out to your sysadmins and retain full control of what's going on under the hood. A PS solution will give you full control, better understanding of underlying process - but that will at cost of time and other design headaches.

To sum up: if you have the time, the will or a specific use case then go with PS. Otherwise do what the big boys do and save yourself reinventing the wheel - or seventeen.

Disclaimer: I did the PS thing for a previous employer.

Raf
  • 8,794
  • 1
  • 25
  • 37
  • Thank you very much for your advice. This is my point of view also. I have 5 month for this project, and i think this is enough. I'll go for PS solution, because it's better to have full control and very interesting to understand underlying process. I already wrote a script to deploy Active Directory, it's working perfectly. In the end, when i'll finish all of my script, i'll try to develop a frontend in html5. – Adeel ASIF Jun 27 '14 at 10:40
0

If you're looking for a repeatable deployment solution, and you don't might using some light, free, infrastructure, I propose you use Windows ADK 8.1 and MDT 2013 (if you're using Windows Server 2012 R2). You can develop a front end to chose a deployment type. Rather than using a csv file, all the information can be contained within the Task Sequence, and can be configured to trigger tasks on different conditions.

Johan Arwidmark from deploymentresearch.com has developed a great example of this called Hydration Kit, with full Step-by-Step Guide that sets up a Configuration Manager 2012 R2 infrastructure, running on Windows Server 2012 R2 and SQL Server 2012 SP1, in either Hyper-V or VMware. If you ask him nicely, he might allow you to use his work as a base for your project.

idarryl
  • 615
  • 1
  • 10
  • 21