Update Public Access Using the Command Line Interface (CLI) Installer

Follow these steps to update the Public Access site using the Command Line Interface (CLI) installer. For more information on configuring Public Access once it's installed, see Public Access Setup Guide on MyCityworks.

IMPORTANT:

  • Due to a change in the underlying .NET architecture, Public Access versions earlier than 6.0 cannot be updated to a 7.x version. Once you have installed a new Public Access site at 6.0 or higher, it can be updated to new versions.
  • In order to use Public Access, a Public Access Role must be defined. This can be any role within the database and will be the role the PA user has access to. This can be done in Admin under PLL > Security Roles > Public Access or in Office Companion under PLL Admin > Public Access Setup > User Roles. See Security Roles in the Admin 3.2 Guide or User Roles in the PLL Admin Office Companion 23 Guide for more information.

PREREQUISITES:

  1. Navigate to where the Public Access installer application is located.
  2. Extract the install file from the zipped file by right-clicking the zipped file and clicking Extract All.
  3. Double-click the unzipped file to open it.
  4. Open the terminal of your choice, such as PowerShell or Command Prompt.
  5. Enter the location of the install files.

  1. Point to the PublicAccess.Installer.CLI.dll file.

The available options and commands show and are listed in the table below.

The installer creates a new app pool for each new site it installs since Microsoft only supports one .NET 7 app per app pool. The app pool is named <site_name>AppPool. The app pool runs as the ApplicationPoolIdentity and the .NET CLR Version is No Managed Code. When the installer creates the app pool, it leaves the Idle Time Out setting to the default IIS setting. The installer does not make updates to existing app pools. When using the CLI installer, you can specify a different identity instead of the app pool identity if you want to. If you do not provide an identity, the CLI installer uses the identity of the app pool by default.

The installer gives the app pool identity Modify permissions to the ClientApp\dist\content\config and ClientApp\dist\profiles folders in the root directory.

When updating a Public Access site, the installer will recycle the app pool. It also attempts to stop the app it is updating and restart it after the update.

When using the CLI installer, you can specify an existing Public Access site as the source for the site files instead of the built-in compressed file. This is helpful when installing a new site that has the same customizations as an existing site; however, the existing Public Access site set as a source location has to match the version of the installer.

When using the CLI installer on Windows, you can provide the folder parameter instead of the site and alias parameters to update the site files without recycling the app pool or stopping the app in IIS.

Option

Description

-im, --installmode <Both|Files|IIS> Whether to run the IIS part of the install, the file part, or both. Possible values are IIS, Files, and Both. <Windows Only> [default: Both]
-s, --site <site> Name of the website to install the application to in IIS. <Required for Windows if --mode is IIS or Both>
-a, --alias <alias> Name of the application to install under the site in IIS. <Required for Windows if --mode is IIS or Both>
-f, --folder <folder> Folder where site files will be installed. <Required for Windows if --mode is Files or Both. Required for Linux.>
-sf, --sourcefolder <sourcefolder> Folder where site files will be installed from. Leave empty to install from the site files included with the installer.
-fpi, --folderpermissionidentity <folderpermissionidentity> Windows identity to give site folder permissions. Defaults to the app pool identity.
-surl, --serviceurl <serviceurl> Url for core Cityworks services. <Required for Windows if --mode is Files or Both. Required for Linux.>. e.g., https://MyServer/MyCityworksSite
-suser, --serviceusername <serviceusername> User name for core Cityworks services. <Required for Windows if --mode is Files or Both. Required for Linux.>
-spass, --servicepassword <servicepassword> User password for core Cityworks services. <Required for Windows if --mode is Files or Both. Required for Linux.>
-t, --timeout <timeout> Timeout in minutes for the Public Access site. [default: 15]
-ga, --guestaccess Allow users to login to the system as a guest. [default: False]
cp, --credentialpass Allow user login credentials to be passed to site. [default: False]
-afe, --allowedfileextensions <allowedfileextensions> List of file extension types users can upoad to the site. It must be a list of file extensions separated by the | character. [default: gif|jpg|jpeg|png|tiff|bmp|pdf|txt|rtf|csv|doc|docx|xls|xlsx|ppt|pptx]
-gc, --gisconfig <gisconfig> Name of GIS Service configuration. [default: Public]
-ug, --usegis Use GIS for location. [default: True]
-rl, --requirelocation Require valid location from GIS. [default: False]
-ma, --mapattachments Allow map drawing attachments. [default: False]
-ur, --userecaptcha Use reCAPTCHA V3. [default: False]
-rk, --recaptchakey <recaptchakey> reCAPTCHA Key. <Required if --userecaptcha is true>
-rs, --recaptchasecret <recaptchasecret> reCAPTCHA Secret. <Required if --userecaptcha is true>
-rm, --recaptchaminscore <recaptchaminscore> Minimum reCAPTCHA score. <Required if --userecaptcha is true> [default: 0.5]
-pp, --paymentprovider Payment Provider. Possible values are None, Paypal, <AuthorizeNet|None|Paypal|XpressBillPay> AuthorizeNet, and XpressBillPay. [default: None]
-pm, --paymentmode <live|sandbox> Payment Mode. Possible values are sandbox and live. [default: sandbox]
-op, --overpayments Allow payments over amount due. [default: False]
-pl, --paymentlog Log info on calls to and from payment provider system. [default: True]
-pc, --paypalclientid <paypalclientid> Paypal Client Id. <Required if --paymentprovider is Paypal>
-pcc, --paypalcurrency <paypalcurrency> Paypal Currency Code. <Required if --paymentprovider is Paypal> [default: USD]
-ps, --paypalsecret <paypalsecret> Paypal Client Secret. <Required if --paymentprovider is Paypal>
-al, --authnetlogin <authnetlogin> Authorize.Net Api Login. <Required if --paymentprovider is AuthorizeNet>
-at, --authnettrans <authnettrans> Authorize.Net Transaction Key. <Required if --paymentprovider is AuthorizeNet>
-w, --webhooks Use Authorize.Net webhooks. [default: False]
-as, --authnetsig <authnetsig> Authorize.Net Signature Key. <Required if --paymentprovider is AuthorizeNet and --webhooks is true>
-xi, --xbpappid <xbpappid> XpressBillPay Application Id. <Required if --paymentprovider is XpressBillPay>
-xk, --xbpappkey <xbpappkey> XpressBillPay Application Key. <Required if --paymentprovider is XpressBillPay>
-xip, --xbpitemized Send Itemized Payments. [default: False]
-xsi, --xbpitemid <xbpitemid> XpressBillPay Single Item Id. <Required if --paymentprovider is XpressBillPay and --xbpitemized is false>
-?, -h, --help Show help and usage information