update comment in the template
[heat-templates.git] / qa / dotnetnuke.template
blobe715673648c4ac958d9860c05e219ccfe04d818a
1 heat_template_version: 2013-05-23
3 description: |
4   HEAT template for installing DotNetNuke app on Windows Server
6 parameters:
8   name:
9     type: string
10     default: HeatWinResource
11     description: Windows Server Name
12     constraints:
13     - length:
14         min: 1
15         max: 64
16     - allowed_pattern: "[a-zA-Z][a-zA-Z0-9]*"
17       description: must begin with a letter and contain only alphanumeric characters.
18     
19   image:
20     type: string
21     default: Windows Server 2012
22     description: Windows Server Image
23   
24   flavor:
25     type: string
26     description: Rackspace Cloud Server flavor
27     default: 4GB Standard Instance
28     constraints:
29     - allowed_values:
30       - 4GB Standard Instance
31       - 8GB Standard Instance
32       - 15GB Standard Instance
33       - 30GB Standard Instance
34       description: must be a valid Rackspace Cloud Server flavor.
35   
36   
37   sql_password:
38     type: string
39     default: verybadpass_123
40     description: SQLExpress DB password
43 resources:
45   rs_windows_server:
46     type: "Rackspace::Cloud::WinServer"
47     properties:
48       name: { get_param: name }
49       flavor: { get_param: flavor }
50       image: { get_param: image }
51       user_data:
52         str_replace:
53           template: |
54             $source = "http://download.microsoft.com/download/7/0/4/704CEB4C-9F42-4962-A2B0-5C84B0682C7A/WebPlatformInstaller_amd64_en-US.msi"
55             $destination = "webpi.msi"
56             $wc = New-Object System.Net.WebClient
57             $wc.DownloadFile($source, $destination)
58             Start-Process msiexec -ArgumentList "/i webpi.msi /qn"  -NoNewWindow -Wait
59             echo "AppPath[@]Default Web Site/dotnetnuke" > dnn.app
60             echo "sqldbpassword[@]${sqlpassword}" >> dnn.app
61             $tmpprofile = $env:userprofile
62             $env:userprofile = "c:\users\administrator"
63             $wpicmd = "C:\Program Files\Microsoft\Web Platform Installer\WebPICMD.exe"
64             Start-Process $wpicmd -ArgumentList "/Install /Application:dotnetnuke@dnn.app /SQLPassword:%sqlpassword% /AcceptEULA /Log:.\wpi.log"  -NoNewWindow -Wait
65             Start-Process 'dism' -ArgumentList "/online /enable-feature /featurename:IIS-ASPNET45 /all" -NoNewWindow -Wait
66             $env:userprofile = $tmpprofile
67           params:
68             "%sqlpassword%": { get_param: sql_password }
71 outputs:
73   public_ip:
74     value: { get_attr: [ rs_windows_server, accessIPv4 ] }
75     description: public IP of the windows server
76   
77   website_url:
78     value:
79       str_replace:
80         template: http://%ip%/dotnetnuke/default.aspx
81         params:
82           "%ip%": { get_attr: [ rs_windows_server, accessIPv4 ] }
83     description: URL for Wordpress site