├── Bootstrap.ps1 ├── LICENSE └── README.md /Bootstrap.ps1: -------------------------------------------------------------------------------- 1 | #====================================================================================================================== 2 | # You may need to change the execution policy in order to run this script 3 | # Run the following in powershell: 4 | # 5 | # Set-ExecutionPolicy RemoteSigned 6 | # 7 | #====================================================================================================================== 8 | # 9 | # FILE: Bootstrap.ps1 10 | # 11 | # DESCRIPTION: Bootstrap salt installation for 64bit windows distributions 12 | # 13 | # BUGS: https://github.com/saltstack/salt-windows-bootstrap/issues 14 | # 15 | # COPYRIGHT: (c) 2012-2015 by the SaltStack Team, see AUTHORS.rst for more 16 | # details. 17 | # 18 | # LICENSE: Apache 2.0 19 | # ORGANIZATION: SaltStack (saltstack.org) 20 | # CREATED: 02/09/2015 21 | #====================================================================================================================== 22 | 23 | # Declare Variables 24 | #-------------------------------------------------------- 25 | $strDownloadDir = "$env:Temp\DevSalt" 26 | $strDevelopmentDir = "C:\Salt-Dev" 27 | $strSaltDir = "C:\salt" 28 | $strWindowsRepo = "http://docs.saltstack.com/downloads/windows-deps" 29 | $strSaltBranch = "develop" 30 | 31 | # Create Directories 32 | #-------------------------------------------------------- 33 | New-Item $strDownloadDir -ItemType Directory -Force 34 | New-Item $strDevelopmentDir -ItemType Directory -Force 35 | New-Item $strSaltDir -ItemType Directory -Force 36 | 37 | #======================================================== 38 | # Define Functions 39 | #======================================================== 40 | Function DownloadFileWithProgress { 41 | 42 | # Code for this function borrowed from http://poshcode.org/2461 43 | # Thanks Crazy Dave 44 | 45 | # This function downloads the passed file and shows a progress bar 46 | # It receives two parameters: 47 | # $url - the file source 48 | # $localfile - the file destination on the local machine 49 | 50 | param( 51 | [Parameter(Mandatory=$true)] 52 | [String] $url, 53 | [Parameter(Mandatory=$false)] 54 | [String] $localFile = (Join-Path $pwd.Path $url.SubString($url.LastIndexOf('/'))) 55 | ) 56 | 57 | begin { 58 | $client = New-Object System.Net.WebClient 59 | $Global:downloadComplete = $false 60 | $eventDataComplete = Register-ObjectEvent $client DownloadFileCompleted ` 61 | -SourceIdentifier WebClient.DownloadFileComplete ` 62 | -Action {$Global:downloadComplete = $true} 63 | $eventDataProgress = Register-ObjectEvent $client DownloadProgressChanged ` 64 | -SourceIdentifier WebClient.DownloadProgressChanged ` 65 | -Action { $Global:DPCEventArgs = $EventArgs } 66 | } 67 | process { 68 | Write-Progress -Activity 'Downloading file' -Status $url 69 | $client.DownloadFileAsync($url, $localFile) 70 | 71 | while (!($Global:downloadComplete)) { 72 | $pc = $Global:DPCEventArgs.ProgressPercentage 73 | if ($pc -ne $null) { 74 | Write-Progress -Activity 'Downloading file' -Status $url -PercentComplete $pc 75 | } 76 | } 77 | Write-Progress -Activity 'Downloading file' -Status $url -Complete 78 | } 79 | 80 | end { 81 | Unregister-Event -SourceIdentifier WebClient.DownloadProgressChanged 82 | Unregister-Event -SourceIdentifier WebClient.DownloadFileComplete 83 | $client.Dispose() 84 | $Global:downloadComplete = $null 85 | $Global:DPCEventArgs = $null 86 | Remove-Variable client 87 | Remove-Variable eventDataComplete 88 | Remove-Variable eventDataProgress 89 | [GC]::Collect() 90 | } 91 | } 92 | 93 | function Update-Environment { 94 | 95 | # This function updates the environment variables 96 | # It is called after installing git and python so that they can be used later in the script 97 | 98 | $locations = 'HKLM:\SYSTEM\CurrentControlSet\Control\Session Manager\Environment', 99 | 'HKCU:\Environment' 100 | 101 | $locations | ForEach-Object { 102 | $k = Get-Item $_ 103 | $k.GetValueNames() | ForEach-Object { 104 | $name = $_ 105 | $value = $k.GetValue($_) 106 | Set-Item -Path Env:\$name -Value $value 107 | } 108 | } 109 | } 110 | 111 | #======================================================== 112 | # Download Prerequisite Files 113 | #======================================================== 114 | 115 | Clear-Host 116 | #-------------------------------------------------------- 117 | # Git 118 | #-------------------------------------------------------- 119 | 120 | # Not necessarily a prerequisite, but needed to pull salt 121 | 122 | # Create the inf file to be passed to the Git executable 123 | Write-Host "Git for Windows" 124 | Write-Host "- creating inf" 125 | Set-Content -path $strDownloadDir\git.inf -value "[Setup]" 126 | Add-Content -path $strDownloadDir\git.inf -value "Lang=default" 127 | Add-Content -path $strDownloadDir\git.inf -value "Dir=C:\Program Files (x86)\Git" 128 | Add-Content -path $strDownloadDir\git.inf -value "Group=Git" 129 | Add-Content -path $strDownloadDir\git.inf -value "NoIcons=0" 130 | Add-Content -path $strDownloadDir\git.inf -value "SetupType=default" 131 | Add-Content -path $strDownloadDir\git.inf -value "Components=ext,ext\cheetah,assoc,assoc_sh" 132 | Add-Content -path $strDownloadDir\git.inf -value "Tasks=" 133 | Add-Content -path $strDownloadDir\git.inf -value "PathOption=Cmd" 134 | Add-Content -path $strDownloadDir\git.inf -value "SSHOption=OpenSSH" 135 | Add-Content -path $strDownloadDir\git.inf -value "CRLFOption=CRLFAlways" 136 | 137 | # Download the file 138 | Write-Host "- downloading file" 139 | $file = "Git-1.9.5-preview20141217.exe" 140 | $url = "$strWindowsRepo\$file" 141 | $file = "$strDownloadDir\$file" 142 | DownloadFileWithProgress $url $file 143 | 144 | # Install the file silently 145 | Write-Host "Installing..." 146 | $p = Start-Process $file -ArgumentList '/SILENT /LOADINF="$strDownloadDir\git.inf"' -Wait -NoNewWindow -PassThru 147 | 148 | Clear-Host 149 | #-------------------------------------------------------- 150 | # Python 2.7 151 | #-------------------------------------------------------- 152 | 153 | # There are problems with 2.7.9, so we're using 2.7.8 154 | 155 | # Download the file 156 | Write-Host "Python 2.7 (entire package)" 157 | $file = "python-2.7.8.amd64.msi" 158 | $url = "$strWindowsRepo\$file" 159 | $file = "$strDownloadDir\$file" 160 | DownloadFileWithProgress $url $file 161 | 162 | # Install the file 163 | Write-Host "Installing..." 164 | $p = Start-Process msiexec -ArgumentList "/i $file /qb ADDLOCAL=ALL" -Wait -NoNewWindow -PassThru 165 | Write-Host "Refreshing the Environment Variables..." 166 | 167 | #-------------------------------------------------------- 168 | # Update Environment Varibales 169 | #-------------------------------------------------------- 170 | $path = [System.Environment]::GetEnvironmentVariable("Path", "Machine") 171 | [System.Environment]::SetEnvironmentVariable("Path", "C:\Program Files (x86)\Git\cmd;C:\Python27;C:\Python27\Scripts;$path", "Machine") 172 | 173 | Update-Environment 174 | 175 | Clear-Host 176 | #-------------------------------------------------------- 177 | # VC++ Compiler for Python 178 | #-------------------------------------------------------- 179 | 180 | # Download the file 181 | Write-Host "Microsoft Visual C++ Compiler for Python (this may take a while)" 182 | $file = "VCForPython27.msi" 183 | $url = "$strWindowsRepo\$file" 184 | $file = "$strDownloadDir\$file" 185 | DownloadFileWithProgress $url $file 186 | 187 | # Install the file 188 | Write-Host "Installing..." 189 | $p = Start-Process msiexec -ArgumentList "/i $file /qb" -Wait -NoNewWindow -PassThru 190 | 191 | Clear-Host 192 | #-------------------------------------------------------- 193 | # Visual C++ 2008 Redistributable 194 | #-------------------------------------------------------- 195 | 196 | # Even though we're installing the patch later, OpenSSL requires this 197 | 198 | # Download file 199 | Write-Host "Microsoft Visual C++ 2008 Redistributable" 200 | $file = "vcredist_x64.exe" 201 | $url = "$strWindowsRepo\$file" 202 | $file = "$strDownloadDir\$file" 203 | DownloadFileWithProgress $url $file 204 | 205 | # Install file 206 | Write-Host "Installing..." 207 | $p = Start-Process $file -ArgumentList "/q" -Wait -NoNewWindow -PassThru 208 | 209 | Clear-Host 210 | #-------------------------------------------------------- 211 | # Visual C++ 2008 Redistrubutable 212 | #-------------------------------------------------------- 213 | 214 | # Download File 215 | Write-Host "Microsoft Visual C++ 2008 MFC Security Update Redistributable" 216 | $file = "vcredist_x64_mfc_update.exe" 217 | $url = "$strWindowsRepo\$file" 218 | $file = "$strDownloadDir\$file" 219 | DownloadFileWithProgress $url $file 220 | 221 | # Install File 222 | Write-Host "Installing..." 223 | $p = Start-Process $file -ArgumentList "/q" -Wait -NoNewWindow -PassThru 224 | 225 | # Copy the libary to the Python directory (for compiling) 226 | Write-Host "copying library file to c:\python27" 227 | $file = "C:\Windows\WinSxS\amd64_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.6161_none_08e61857a83bc251\msvcp90.dll" 228 | Copy-Item $file C:\Python27 -Force 229 | 230 | Clear-Host 231 | #-------------------------------------------------------- 232 | # OpenSSL 233 | #-------------------------------------------------------- 234 | 235 | # Download file 236 | Write-Host "Open SSL for Windows (Light)" 237 | $file = "Win64OpenSSL_Light-1_0_1L.exe" 238 | $url = "$strWindowsRepo\$file" 239 | $file = "$strDownloadDir\$file" 240 | DownloadFileWithProgress $url $file 241 | 242 | # Install file 243 | Write-Host "Installing..." 244 | $p = Start-Process $file -ArgumentList "/silent" -Wait -NoNewWindow -PassThru 245 | 246 | Clear-Host 247 | #-------------------------------------------------------- 248 | # M2Crypto 249 | #-------------------------------------------------------- 250 | 251 | # Couldn't find a version of this I could install silently 252 | # Install created with distutils which has no silent option 253 | 254 | # Download file 255 | Write-Host "M2Crypto" 256 | $file = "M2Crypto-0.21.1.win-amd64-py2.7.exe" 257 | $url = "$strWindowsRepo\$file" 258 | $file = "$strDownloadDir\$file" 259 | DownloadFileWithProgress $url $file 260 | 261 | # Install file (requires the user to click through it) 262 | Write-Host "Installing..." 263 | $p = Start-Process $file -Wait -NoNewWindow -PassThru 264 | 265 | Clear-Host 266 | #-------------------------------------------------------- 267 | # PyWin32 268 | #-------------------------------------------------------- 269 | 270 | # Again, couldn't find a version that could install silently 271 | # Install created with distutils which has no silent option 272 | 273 | # Download file 274 | Write-Host "pywin32" 275 | $file = "pywin32-219.win-amd64-py2.7.exe" 276 | $url = "$strWindowsRepo\$file" 277 | $file = "$strDownloadDir\$file" 278 | DownloadFileWithProgress $url $file 279 | 280 | # Install file 281 | Write-Host "Installing..." 282 | $p = Start-Process $file -Wait -NoNewWindow -PassThru 283 | 284 | Clear-Host 285 | #-------------------------------------------------------- 286 | # Make 287 | #-------------------------------------------------------- 288 | 289 | # Download file 290 | Write-Host "make" 291 | $file = "make.exe" 292 | $url = "$strWindowsRepo\$file" 293 | $file = "$strDownloadDir\$file" 294 | DownloadFileWithProgress $url $file 295 | 296 | # Copy to the python directory 297 | Write-Host "Copying to Python27 directory..." 298 | Copy-Item $file C:\Python27 -Force 299 | 300 | Clear-Host 301 | #-------------------------------------------------------- 302 | # pefile 303 | #-------------------------------------------------------- 304 | 305 | # Download file 306 | Write-Host "pefile" 307 | $file = "pefile-1.2.10-139.zip" 308 | $url = "$strWindowsRepo\$file" 309 | $file = "$strDownloadDir\$file" 310 | DownloadFileWithProgress $url $file 311 | 312 | # Unzip the package 313 | Write-Host "Unzipping..." 314 | $shell = New-Object -ComObject Shell.Application 315 | $item = $shell.NameSpace("$file\pefile-1.2.10-139") 316 | $path = Split-Path (Join-Path $strDownloadDir "pefile-1.2.10-139") 317 | if (!(Test-Path $path)) {$null = mkdir $path} 318 | $shell.NameSpace($path).CopyHere($item) 319 | Write-Host "Installing..." 320 | 321 | # Install the package 322 | Set-Location -Path $strDownloadDir\pefile-1.2.10-139 323 | $p = Start-Process python -ArgumentList "setup.py install" -Wait -NoNewWindow -PassThru 324 | 325 | Clear-Host 326 | #-------------------------------------------------------- 327 | # easy_install 328 | #-------------------------------------------------------- 329 | 330 | # This was installed with python 2.7.9 331 | # Now that we're using python 2.7.8, we have to install it 332 | 333 | # Download file 334 | Write-Host "easy_install" 335 | $file = "ez_setup.py" 336 | $url = "$strWindowsRepo\$file" 337 | $file = "$strDownloadDir\$file" 338 | DownloadFileWithProgress $url $file 339 | 340 | # Copy to the python directory 341 | Write-Host "Copying to Python27 directory..." 342 | Copy-Item $file C:\Python27 -Force 343 | 344 | #======================================================== 345 | # Clone the Salt Repository 346 | #======================================================== 347 | 348 | # This needs to be done here in order for the config file copy to be successful 349 | # For some reason it failed if you tried to copy the config right after the clone 350 | 351 | # Clone Salet 352 | Write-Host "Cloning the SaltStack Git Repository" 353 | Set-Location -Path "$strDevelopmentDir" 354 | $p = Start-Process git -ArgumentList "clone https://github.com/saltstack/salt" -Wait -NoNewWindow -PassThru 355 | 356 | # Checkout the branch 357 | Set-Location -Path "$strDevelopmentDir\Salt" 358 | $p = Start-Process git -ArgumentList "checkout $strSaltBranch" -Wait -NoNewWindow -PassThru 359 | 360 | #======================================================= 361 | # Install additional prerequisites 362 | #======================================================= 363 | 364 | # install prerequisites using ez_insatll and pip 365 | # Pip has a hard time compiling some of the binaries 366 | Write-Host "Setting up the environment" 367 | Set-Location -Path C:\Python27 368 | $p = Start-Process python -ArgumentList "ez_setup.py" -Wait -NoNewWindow -PassThru 369 | $p = Start-Process easy_install -ArgumentList "pip" -Wait -NoNewWindow -PassThru 370 | $p = Start-Process pip -ArgumentList "install pycrypto" -Wait -NoNewWindow -PassThru 371 | $p = Start-Process pip -ArgumentList "install cython" -Wait -NoNewWindow -PassThru 372 | $p = Start-Process pip -ArgumentList "install jinja2" -Wait -NoNewWindow -PassThru 373 | $p = Start-Process pip -ArgumentList "install msgpack-python" -Wait -NoNewWindow -PassThru 374 | $p = Start-Process pip -ArgumentList "install psutil" -Wait -NoNewWindow -PassThru 375 | $p = Start-Process pip -ArgumentList "install pyyaml" -Wait -NoNewWindow -PassThru 376 | $p = Start-Process easy_install -ArgumentList "pyzmq==13.1.0" -Wait -NoNewWindow -PassThru 377 | $file = "C:\Python27\Lib\site-packages\pyzmq-13.1.0-py2.7-win-amd64.egg\zmq\libzmq.pyd" 378 | Copy-Item $file C:\Python27 -Force 379 | $p = Start-Process pip -ArgumentList "install wmi" -Wait -NoNewWindow -PassThru 380 | $p = Start-Process pip -ArgumentList "install requests" -Wait -NoNewWindow -PassThru 381 | $p = Start-Process pip -ArgumentList "install six" -Wait -NoNewWindow -PassThru 382 | $p = Start-Process pip -ArgumentList "install certifi" -Wait -NoNewWindow -PassThru 383 | $p = Start-Process pip -ArgumentList "install esky" -Wait -NoNewWindow -PassThru 384 | $p = Start-Process easy_install -ArgumentList "bbfreeze" -Wait -NoNewWindow -PassThru 385 | $p = Start-Process pip -ArgumentList "install sphinx==1.3b2" -Wait -NoNewWindow -PassThru 386 | 387 | #-------------------------------------------------------- 388 | # Install Salt 389 | #-------------------------------------------------------- 390 | Set-Location -Path "$strDevelopmentDir\salt" 391 | Start-Process python -ArgumentList "setup.py install --force" -Wait -NoNewWindow -PassThru 392 | 393 | #-------------------------------------------------------- 394 | # Remove the temperary download directory 395 | #-------------------------------------------------------- 396 | Write-Host "Cleaning up downloaded files" 397 | Remove-Item $strDownloadDir -Force -Recurse 398 | 399 | #-------------------------------------------------------- 400 | # Copy salt config files to salt directory 401 | #-------------------------------------------------------- 402 | Write-Host "Copying Salt Config Files..." 403 | $strConfigFiles = "$strDevelopmentDir\salt\pkg\windows\buildenv" 404 | Copy-Item $strConfigFiles\* $strSaltDir -Recurse -Force 405 | 406 | #-------------------------------------------------------- 407 | # Script complete 408 | #-------------------------------------------------------- 409 | Write-Host "Salt Stack Dev Environment Script Complete" 410 | Write-Host "Press any key to continue ..." 411 | $HOST.UI.RawUI.Flushinputbuffer() 412 | $HOST.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown") 413 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "{}" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright {yyyy} {name of copyright owner} 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | 203 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Dev Environment Installation (bootstrap) 2 | 3 | ## Description 4 | Powershell script to bootstrap python and all dependencies for the Salt Minion. Useful for development purposes. Git and all salt dependencies are installed. Salt is cloned to "C:\Salt-Dev". Configuration files are placed in "C:\Salt". All executables are downloaded from [SaltStack's win-repo](http://docs.saltstack.com/downloads/windows-deps/). 5 | 6 | Source and target directories can be changed by editing variables towards the top. of the file. 7 | 8 | You'll still need to edit the minion configuration file in order to run salt-minion. 9 | 10 | ## Notes 11 | If the script fails to run, you may need to change the execution policy. Run the following in powershell: 12 | Set-ExecutionPolicy RemoteSigned 13 | 14 | ## Warning 15 | This script will overwrite existing config files in C:\salt. 16 | --------------------------------------------------------------------------------