Form deployment and security
caution
Temenos Journey Manager (TJM) 21.11 introduced changes to the Workspaces REST API that are incompatible with earlier releases. Consequently, the Workspaces 19.11 application cannot be used with a TJM 21.11 or later instance, and you must upgrade your Workspaces application to an Open UX form.
Prerequisites
Before deploying Journey Workspaces as an Open UX form, be sure to address the following in your project.
- Ensure the index file for the configuration is updated with all the defined spaces required in the application.
- Ensure the application's
transact-config.json
is updated to point to the correct configuration path. - Ensure the application's locale setting is defined correctly in the index file.
Deployment
Before deploying your Workspaces form, make sure you have a .transact-auth
file at the root of your project with the following details relating to your TJM environment.
tmHost=JM_SERVER
username=JM_USERNAME
password=JM_PASSWORD
tip
Journey Workspaces allows you to use .transact-auth
variables inside transact-config.json
. To learn more, see Transact Config.
Replace the following:
JM_SERVER
: The URL for your Journey Manager server where the application will be deployed. For example,https://tm.workspaces.avoka-transact.com
.JM_USERNAME
,JM_PASSWORD
: Your credentials to authenticate onJM_SERVER
.
Then, run the following command to deploy your form to the configured environment:
npm run build:deploy
If JM is behind a proxy, use the following command instead:
npm run build:deploy -- --proxy-host=HOST --proxy-port=PORT --proxy-username=USERNAME --proxy-password=PASSWORD
Replace HOST
, PORT
, USERNAME
and PASSWORD
with the relevant details for your environment.
info
If you're deploying your Workspaces form to a local instance of JM, make sure the URL does not contain /secure/
. That is:
http://localhost:9080/workspaces/app/FORM_CODE/FORM_VERSION
http://localhost:9080/workspaces/secure/app/FORM_CODE/FORM_VERSION
Security
When you first deploy your Workspaces form, JM deploys it with the Authenticated and Anonymous modes enabled to all form spaces that belong to your organization. This behavior is expected for Open UX forms, but it's not what we need for a Workspaces form. Instead, we need to restrict form access to just the form space where the Workspaces WAR file is deployed (Work Spaces, by default), and with Authenticated mode enabled only.
To achieve this, follow these steps:
- Select Forms > Forms.
- Locate your form by Form Name, and click the Form Name or the form's Edit icon.
- Switch to the Spaces tab.
- Ensure that only the Work Spaces form space is in the list. Remove any other form spaces from the list.
- For the Work Spaces form space, ensure that only Authenticated Access is enabled. If Anonymous Access is enabled, click the Edit icon and clear the Anonymous Access checkbox.
- Click Save.
note
If you have renamed the Workspaces form space (Work Spaces, by default), make sure you associate the correct form space with your Workspaces form in the steps above.
Finally, the Workspaces WAR file comes with default index.htm
and logout.htm
files that need to be updated with the new form URL so that all default routes redirect to the new Workspaces form.
- In Journey Manager, select Forms > Form Spaces.
- In the list of form spaces, locate the Workspaces form space that you want to edit and click the Edit icon for that space.
- Select the Pages tab, and copy the following template into
index.htm
andlogout.htm
.Replace<html>
<head>
<meta http-equiv="Refresh" content="0;URL=/workspaces/app/FORM_CODE/FORM_VERSION" />
</head>
</html>FORM_CODE
andFORM_VERSION
with appropriate values for your form.
You're all set now!
We have built-in standard components, mock data, hot module reloading, state management, and i18n. Continue exploring our documentation to learn about these topics.