-
Notifications
You must be signed in to change notification settings - Fork 0
Home
PowerShell DSC (Desired State Configuration) is a powerful tool for automating the deployment and management of ArcGIS Enterprise. This repository provides a set of PowerShell scripts that help standardize, simplify, and scale ArcGIS Enterprise deployments and upgrades.
PowerShell DSC offers numerous advantages, including:
- Standardization: Ensures consistent deployments across environments.
- Automation: Reduces manual effort and human error.
- Scalability: Supports large-scale deployments with ease.
- Version Control: Keeps track of configuration changes.
- Customization: Adaptable to various IT environments and requirements.
This repository contains:
- PowerShell DSC Helper Scripts: Scripts to assist with setting up and managing DSC configurations, as well as installing, upgrading and troubleshooting ArcGIS deployments using PowerShell DSC.
Ensure you have the following before deploying:
- Licenses for all Esri software you'd like to install
- Certificates for your deployment (this includes
.ceror.crtformat public key certificates for building trust chains, as well as.pfxprivate key certificates for encryption) - Domain Service Account:
domain\SvcAccount - MyEsri account (SAML logins are not supported for DSC downloads)
- Required Ports Open:
- see full list of required ports for ArcGIS Enterprise here , as well as the Windows Remote Management ports used by PowerShell DSC
:5985/:5986, and the SMB protocol port used by the transfer Helper Scripts:445
- see full list of required ports for ArcGIS Enterprise here , as well as the Windows Remote Management ports used by PowerShell DSC
- Necessary ArcGIS Enterprise file path exclusions added to your antivirus software:
- See this document in the ArcGIS Trust Center for full list of exclusion paths needed. Note: ArcGIS login required.
- A supported web browser (Edge, Firefox or Chrome)
- All machine names and aliases to be used in the deployment
- Any ODBC drivers that will be installed
For Disconnected Environments In addition to the prerequisites listed above
- Installer files downloaded from My Esri
- Esri patches downloaded from the Esri Support site
- (If installing Enterprise 11.1+) The Microsoft IIS dependencies for Web Adaptor
Web Deploy 4.0and theASP .NET 8.x Hosting Bundle
- Run the
enterPsSession.ps1Helper Script to test for Windows Remote Management connectivity between nodes. - Run the
clearDscCache.ps1andlocalLcmSet.ps1Helper Scripts to clean up and configure the PowerShell DSC environment - Install the ArcGIS PowerShell DSC module:
- Installation Guide
- Alternatively, you can use the
downloadUpgradeArcgisModule.ps1Helper Script, which will remove any existing module from each machine and download the most-recent version of the ArcGIS module. This script requires internet access.
- If in a disconnected environment, ensure all required files are downloaded manually to each machine in the deployment. After downloading the module manually to the orchestration server, you may optionally use the
transferModule.ps1script to move the module to each node in the deployment. This script does not require internet access.
- Define the folder structure for certificates, licenses, passwords, installers and patches (only needed if in a disconnected environment), DSC configuration files and helper scripts.
- Transfer the certificates, licenses, any ODBC drivers, and installers and patches (if disconnected) to all nodes in the deployment using the
transferCertificates.ps1,transferLicenses.ps1,transferODBC.ps1, andtransferInstallers.ps1(only needed if not using PSDSC for downloading the installers) Helper Scripts - Generate password files using the
generatePwFiles.ps1Helper Script
- Use a text editor like Visual Studio Code or Notepad++.
- Reference the sample configuration templates as a starting point:
- Follow variable reference guides to fine-tune your .json configuration file to your deployment:
Open PowerShell ISE and change the working directory to the root of your folder structure
cd C:\AutomationUse the Invoke-ArcGISConfiguration cmdlet to execute the deployment:
Invoke-ArcGISConfiguration -ConfigurationParametersFile "C:\Automation\dsc\BaseEnterpriseDeployment.json" -Mode InstallLicenseConfigure -DebugSwitchAlternatively, use the InvokeScript_Install.ps1 Helper Script which performs both of the above commands for you.
More details on the Invoke cmdlet:
Upgrades follow a similar process to initial deployments:
- Check Prerequisites
- Update PowerShell DSC Environment
- Update Server Environment
- Modify JSON Configuration File
-
Run the Upgrade Command
Invoke-ArcGISConfiguration -ConfigurationParametersFile "C:\Automation\dsc\BaseEnterpriseDeployment.json" -Mode Upgrade
- Check Logs: Review logs for errors and warnings including PowerShell logs, ArcGIS Enterprise application logs and Windows Event Viewer logs.
- Validate Configuration: Ensure the JSON configuration file is properly structured using a .json validator.
-
Check for network issues: Use commands like
netstat -anoin Command Prompt ortest-netconnection -computername server.domain.com -port 7443in PowerShell to test for network-related problems between nodes - Reference Documentation: Issues forum, Discussions forum
This GitHub wiki serves as a guide for using PowerShell DSC to automate ArcGIS Enterprise installations and upgrades efficiently. For further inquiries, feel free to submit an issue on this repository.