Skip to content

Conversation

mu88
Copy link

@mu88 mu88 commented Apr 5, 2017

These commits enable the Cookbook to create backups of ArcGIS Server Site or the complete WebGIS (ArcGIS Server, Portal for ArcGIS, ArcGIS Data Store). It only works for Windows. There is an additional task to delete backups after a defined number of days.
The configuration is ease:

  • node['arcgis']['backups']['site_backup_dir'] --> the location where the backup of ArcGIS Server Site will be placed
  • node['arcgis']['backups']['webgis_backup_dir'] --> the location where the backup of ArcGIS Server Site will be placed

Under the hood, the code does the following:

  1. Privilege the user node['arcgis']['run_as_user'] within Windows to log on as batch job
  2. If Portal is installed --> configure WebGIS-Backup-Configuration-File <<Portal-Install-Dir>>\tools\webgisdr\Custom_webgisdr.properties
  3. If Portal for ArcGIS is installed --> create a Windows Scheduled Task to call <<Portal-Install-Dir>>\webgisdr.bat with the previously configured WebGIS-Backup-Configuration-File
  4. If Portal is not installed, but ArcGIS Server is --> create a Windows Scheduled Task to call <<Server-Install-Dir>>\tools\admin\backup.py with the appropriate arguments
  5. Create a Windows Scheduled Task to delete backup files if they are older than a defined number of days (node['arcgis']['backups']['retention_period'])

Unfortunately, I was not able to implement step 1 with either pure Ruby or Chef code. I use the additional PowerShell Module Carbon for this - the installation of Carbon is done within a dedicated PowerShell script that I execute before Chef.
@pbobov Maybe you find a better solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant