Shramp Posted November 5, 2019 Posted November 5, 2019 (edited) I created a simple script to update the Pulseway Manager settings. The script verifies if a directory exists, and if it doesn't then creates it. Afterwards, it downloads the file from the URL and saves it to the outpath. Then updates Pulseway Manager config with the file located in the outpath. This has been extremely useful for modifying settings and updating all agents with the new settings. The flow for this process is as follows: 1. Update settings on the Pulseway Manager application, export settings. 2. Upload the settings file to a cloud or web-based URL, I use AWS S3 buckets with a public URL. 3. Add the URL to the $url variable, and change the paths depending on your environment. 4.Create a task on Pulseway to run this a few times, to make sure everybody has their settings synced up properly. **The config password should be blank if you didnt export with a password. If you exported with a password, put the password after configpassword=** $url = "url-to-site-that-hosts-file (s3 bucket, google drive, etc)" $outpath = "C:\IT\pulsewaysettingsupdate.pcmcfg" $path = "C:\IT" If(!(test-path $path)) { New-Item -ItemType Directory -Force -Path $path } $WebClient = New-Object System.Net.WebClient $WebClient.DownloadFile($url, $outpath) "C:\Program Files\Pulseway\PCMonitorManager.exe /config=C:\IT\updatedDomainSettings.pcmcfg /configpassword=auto@2017" updateSettingsForAgent.ps1 Edited November 13, 2019 by Shramp missed adding an important point, grammar
farsidetech Posted January 14, 2020 Posted January 14, 2020 I seem to be having some issues with it, it is downloading the file, but no settings seem to be changing
Staff Chris Posted January 16, 2020 Staff Posted January 16, 2020 Hi @farsidetech, Have you tried to run the same command locally on your system to import config file? Is it successful? "C:\Program Files\Pulseway\PCMonitorManager.exe /config=C:\IT\updatedDomainSettings.pcmcfg /configpassword=auto@2017" If it is successful, then try to use the following line in your powershell script: cmd.exe /c '"C:\Program Files\Pulseway\PCMonitorManager.exe /config=C:\IT\updatedDomainSettings.pcmcfg /configpassword=auto@2017"'
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now