alteryx-deploy
is a small PowerShell utility for the automation of the deployment and maintenance of Alteryx.
Download the latest stable version from the alteryx-deploy
GitHub repository.
curl --remote-name --remote-header-name "https://github.com/Akaizoku/alteryx-deploy/releases/download/2.0.0/alteryx-deploy-v2.0.0.zip"
Alternatively, if you do not wish to install the PowerShell modules required as dependencies, you can download the portable version.
curl --remote-name --remote-header-name "https://github.com/Akaizoku/alteryx-deploy/releases/download/2.0.0/alteryx-deploy-v2.0.0-portable.zip"
A set-up wizard is available to interactively configure the script from the command prompt.
.\Deploy-Alteryx.ps1 -Action "setup"
- Run the
Deploy-Alteryx.ps1
script with the corresponding action parameter;- activate: activate the Alteryx application license
- backup: backup the Alteryx application database
- configure: configure the Alteryx application
- deactivate: deactivate the Alteryx application license
- download: download latest Alteryx application release
- help display the help documentation of the script
- install: install the Alteryx application
- open: open the Alteryx application
- patch: patch upgrade the Alteryx application
- ping: check the status of the Alteryx application
- repair: repair the Alteryx application database
- restart: restart the Alteryx application
- restore: restore a backup of the Alteryx application database
- rollback restore a previous known state of the Alteryx application
- setup: set-up the script configuration
- show: display the script configuration
- start: start the Alteryx application
- stop: stop the Alteryx application
- uninstall: uninstall the Alteryx application
- upgrade: upgrade the Alteryx application
- Check the logs.
Example to display the current script configuration:
.\Deploy-Alteryx.ps1 -Action "show"
Remark It is strongly recommended to perform a test run using the -WhatIf
parameter if you are running the script or operation for the first time.
This script requires administrator rights to be run.
This script requires PowerShell version 5.0 or later to be run.
This script makes use of functions from the PowerShell Tool Kit (PSTK) module and Alteryx PowerShell (PSAYX) module as described in the dependencies section.
The modules must be installed on the local machine, or placed in the lib
folder at the root of the script directory.
Install-Module -Name "PSTK"
Install-Module -Name "PSAYX"
Alternatively, do install the portable version of the script made available in the alteryx-deploy
GitHub repository.
Example script structure with embedded dependencies:
.alteryx-deploy
+---conf
+---lib
| +---PSAYX
| \---PSTK
+---powershell
\---res
Alteryx installation files must be made available in the source directory (default C:\Sources
). See the compatibility section for more information about the supported versions.
You can download them from https://downloads.alteryx.com or download via the download
action.
Please refer to Alteryx system requirements for minimum machine requirements.
In addition to the configuration files presented above, parameters will define the operation performed during the execution.
This section lists the mandatory parameters that must be specified to run the script.
The Action
parameter corresponds to the operation to perform.
Nineteen options are available:
- activate: activate the Alteryx application license
- backup: backup the Alteryx application database
- configure: configure the Alteryx application
- deactivate: deactivate the Alteryx application license
- download: download latest Alteryx application release
- help: display the help documentation
- install: install the Alteryx application
- repair: repair the Alteryx application database
- open: open the Alteryx application
- patch: patch upgrade the Alteryx application
- ping: check the status of the Alteryx application
- repair: repair the Alteryx application database
- restart: restart the Alteryx application
- restore: restore a backup of the Alteryx application database
- rollback: restore a previous known state of the Alteryx application
- setup: set-up the script configuration
- show: display the script configuration
- start: start the Alteryx application
- stop: stop the Alteryx application
- uninstall: uninstall the Alteryx application
- upgrade: upgrade the Alteryx application
This section lists the optional parameters that can be specified at runtime.
The Version
parameter is optional and enables the user to overwrite the version set in the configuration files.
The BackupPath
parameter is optional and enables the user to specify a backup file to use for a database restore.
The Product
parameter is optional and enables the user to define if Alteryx Designer should be installed instead of the default Alteryx Server.
The LicenseKey
parameter is optional and enables the user to specify license keys at runtime.
The Unattended
switch enables the user to specify that the script should run without any interaction.
If this switch is not used, the setup wizard from Alteryx will be displayed and the user will need to go through the installation steps manually.
The WhatIf
switch enables the user to test a command without executing the actions of the command. This means that changes are not applied but processing steps are simply displayed.
The Debug
standard switch enable the display of additional log information.
A lot of useful debug messages have been defined. Should you wish to enable them, it is recommended to make use of the $DebugPreference
variable.
$DebugPreference = "Continue"
Below are the execution steps of the .\Deploy-Alteryx.ps1
script.
Remarks:
- The execution steps will vary depending on the configuration of the scripts.
- The steps described below correspond to a complete and successfull execution of the script.
Display the help documentation of the script.
Get-Help -Name "Deploy-Alteryx.ps1" -Full
Start the configuration wizard to guide the user through the set-up of the alteryx-deploy script.
Below are the steps to set-up the alteryx-deploy
script configuration.
.\Deploy-Alteryx.ps1 -Action "setup"
- Configure script parameters;
- Configure license API token;
- Configure Server API admin keys;
- Configure installation properties;
- Configure license key file
Display the current script configuration back to the user.
Below are the steps to display the alteryx-deploy
script configuration.
.\Deploy-Alteryx.ps1 -Action "show"
Download the latest version of the licensed Alteryx application from the Alteryx license portal.
Below are the steps to download the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "download"
- Refresh license API portal access token;
- Fetch information on latest release;
- Download latest version of Alteryx Server (or Designer if specified with the
-Product
parameter); - Download Predictive Tools (if enabled);
- Download Intelligence Suite (if enabled).
Start the installation process of the Alteryx application and its add-ons if configured.
Below are the steps to install the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "install"
- Install Alteryx Server (or Designer if specified with the
-Product
parameter); - Install Predictive Tools (if enabled);
- Install Intelligence Suite (if enabled);
- Install Data packages (if enabled);
- Activate licenses (if enabled).
Start the (major) upgrade process of the Alteryx application and its add-ons if configured.
Below are the steps to upgrade the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "upgrade"
- Backup Alteryx database and configuration files;
- Upgrade Alteryx Server (or Designer if specified with the
-Product
parameter); - Install Predictive Tools (if enabled);
- Install Intelligence Suite (if enabled);
- Install Data packages (if enabled);
- Check installation status and rollback if errors occurred.
Start the patch process of the Alteryx application.
Below are the steps to patch the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "patch"
- Backup Alteryx database and configuration files;
- Patch Alteryx Server (or Designer if specified with the
-Product
parameter); - Check installation status.
Start the uninstallation process of the Alteryx application and all of its add-ons.
Below are the steps to uninstall the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "uninstall"
- Uninstall Alteryx Server (or Designer if specified with the
-Product
parameter).
Warnings:
- The uninstallation process requires the original installation executable file.
- The uninstallation of Alteryx Server does also remove all dependencies such as Precdictive Tools, Intelligence Suite, etc.
License the Alteryx application by registering the specified license keys through the Alteryx licensing system.
Below are the steps to activate (license) the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "activate"
- Check licensing system connectivity (whitelist.alteryx.com);
- Check license file path;
- Activate Alteryx licenses.
Deregister the specified license keys through the Alteryx licensing system.
Below are the steps to deactivate (license) the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "deactivate"
- Check licensing system connectivity (whitelist.alteryx.com);
- Check license file path;
- Deactivate Alteryx licenses.
Start the back-up process of the Alteryx database and all of the configuration files of the application.
Below are the steps to back-up the Alteryx application database.
.\Deploy-Alteryx.ps1 -Action "backup"
- Check Alteryx Service status and stop it if it is running;
- Create database dump;
- Create copy of application configuration files;
- Backup controller token;
- Compress all back-up files;
- Restart Alteryx Service (if it was running previously).
Start the restoration process of the Alteryx database and all of the configuration files of the application from a back-up file.
Below are the steps to restore the Alteryx application database.
.\Deploy-Alteryx.ps1 -Action "restore"
- Check Alteryx Service status and stop it if it is running;
- Check backup path;
- If backup file is an archive (.ZIP), extract files from archive.
- If backup path is a directory, select most recent backup file (using last write time).
- Restore application configuration files;
- Update configuration to match new environment;
- Restore controller token;
- Reset storage keys;
- Restore MongoDB database;
- Restart Alteryx Service (if it was running previously).
Start the repair process of the Alteryx database.
Below are the steps to repair the Alteryx application database.
.\Deploy-Alteryx.ps1 -Action "repair"
- Rebuild MongoDB indexes.
Remark: No repair steps are available for version 2022.1 and above.
Start the rollback process of the Alteryx application back to a previous known state from a back-up file.
Below are the steps to roll-back the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "rollback"
- Uninstall the current version;
- Install previous version;
- Restore database;
- Restart service.
Start the Alteryx service.
Below are the steps to start the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "start"
- Check Alteryx Service status;
- If it is not already running, start Alteryx Service;
- Check if the service started properly.
Stop the service powering the Alteryx application.
Below are the steps to stop the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "stop"
- Check Alteryx Service status;
- If it is not already stopped, stop Alteryx Service;
- Check if the service stopped properly.
Restart the service powering the Alteryx application.
Below are the steps to restart the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "restart"
- Stop Alteryx Service;
- Start Alteryx Service.
Check the status of the service powering the Alteryx application and the connectivity to the Gallery.
Below are the steps to ping the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "ping"
- Check that the Alteryx Service is running;
- Check the HTTP status of the Gallery.
Open the user interface of the Alteryx application.
Below are the steps to open the Alteryx application.
.\Deploy-Alteryx.ps1 -Action "open"
- Server: open the Gallery using the default web-browser;
- Designer: open the GUI.
Transcript log files are generated in the log directory of the script.
- The naming convention of the transcript log file is:
<Timestamp>_<Action>-Alteryx.log
- The format of the log is:
<Timestamp>\t<Message type>\t<Message>
Additional log files are generated by InstallAware during the installation, upgrade, or uninstallation of Alteryx as an XML file in the same log directory. Those are disabled by default because of the negative impact on the speed of execution, but they can be enabled by setting the configuration variable InstallAwareLog
to true
.
The naming convention of the InstallAware log file is: <Timestamp>_<Setup.exe>.log
Below is an example of a successful installation log:
2021-11-15 10:09:36 INFO Installation of Alteryx Server 2021.3.3.63061
2021-11-15 10:09:36 INFO Installing Alteryx Server
2021-11-15 10:34:14 CHECK Alteryx Server installed successfully
2021-11-15 10:34:14 WARN Do not forget to configure system settings
2021-11-15 10:34:14 INFO Installing Predictive Tools
2021-11-15 10:36:45 CHECK Predictive Tools installed successfully
2021-11-15 10:36:45 INFO Installing Intelligence Suite
2021-11-15 10:49:36 CHECK Intelligence Suite installed successfully
2021-11-15 10:49:36 INFO Activating Alteryx license
2021-11-15 10:49:36 INFO Checking licensing system connectivity
2021-11-15 10:49:54 CHECK 3 licenses were successfully activated
2021-11-15 10:49:54 CHECK Alteryx Server 2021.3.3.63061 installed successfully
This module depends on the usage of functions provided by two PowerShell modules:
- PowerShell Tool Kit (PSTK) module (version 1.2.6);
- Alteryx PowerShell (PSAYX) module (version 1.1.1).
Below are listed the compatible versions for each of the release.
Only the first version supported is listed. Later releases should also be compatible as long as no breaking change has been introduced. Please refer to the Alteryx release notes for more information.
alteryx-deploy |
Alteryx | PowerShell | PSTK | PSAYX |
---|---|---|---|---|
1.0.0 | 2021.3 | 5.0 | 1.2.4 | 1.0.0 |
1.1.0 | 2021.3 | 5.0 | 1.2.5 | 1.0.1 |
1.1.1 | 2021.3 | 5.0 | 1.2.5 | 1.0.1 |
1.1.2 | 2021.3 | 5.0 | 1.2.5 | 1.0.1 |
2.0.0 | 2024.1 | 5.0 | 1.2.6 | 1.1.1 |
Below are listed known issues that might occur depending on your environment.
Please report any new problem using the GitHub repository issue page.
This error can occur during the backup of the application when OneDrive is installed and is synchronising the temporary backup files while the script attempts to remove them (see PowerShell issue #9246 for more information).
This has no impact on the backup process and only affects temporary files used to generate the backup archive.
2021-11-21 02:12:55 INFO Remove staging backup folder 2021-11-21 02:12:55 ERROR Access to the cloud file is denied
It can be prevented by configuring a temporary directory (TempDirectory
) that is not synchronised by OneDrive. Temporary files can also be removed manually.
It appears that in some environments, the transcript it not stopped as expected when exiting the script.
If this occurs, simply run the command Stop-Transcript
or Stop-AllTranscripts
.