Rockwell Automation maintains these repositories as a convenience to you and other users. Although Rockwell Automation reserves the right at any time and for any reason to refuse access to edit or remove content from this Repository, you acknowledge and agree to accept sole responsibility and liability for any Repository content posted, transmitted, downloaded, or used by you. Rockwell Automation has no obligation to monitor or update Repository content
The examples provided are to be used as a reference for building your application and should not be used in production as-is. It is recommended to adapt the example for the purpose, of observing the highest safety standards.
This repository contains the required files to build and run a Docker Container with the Factory Talk Optix Update Service.
- This procedure involves some good knowledge of Linux systems and Docker containers and it is intended for advanced users
- The default entry point is the
FTOptixApplicationUpdateServer
itself - The final container should be set to restart automatically on fail.
- Upgrade of the
UpdateServer
via FactoryTalk® Optix™ IDE is not supported - The default user is
admin
and the password isFactoryTalkOptix
- To activate a license and run the container for more than 120 minutes, internet connectivity to the Rockwell Automation cloud must be available at all times
- If no internet connectivity is available, the FactoryTalk® Optix™ Application will be stopped after 120 minutes and must be deployed again from FactoryTalk® Optix™ Studio
- The license is passed to the container as an environment variable, this variable is then periodically checked to a Rockwell Automation server to check its validity
- FactoryTalk® Optix™ version 1.4.0.450 or later
- Docker engine must be installed and running
- Refer to the (official documentation)
- (optional) Set users' right to access the Docker socket with either one of these steps if you want to execute the container as non-root:
- Changing the socket permissions with:
sudo chmod 666 /var/run/docker.sock
(valid up to next reboot) - Configuring the Docker group (official documentation)
- Add the new group:
sudo groupadd docker
- Add the current user to the Docker group:
sudo usermod -aG docker $USER
- Reboot the machine to apply changes
- Add the new group:
- Changing the socket permissions with:
- FactoryTalk® Optix™ studio installed on your development machine
- Licensing on Docker containers is only supported starting from FactoryTalk® Optix™ 1.4.0.450
- A proper Runtime license must be available to execute the container for more than two hours
- This step is optional, if not properly licensed, the FactoryTalk® Optix™ Application will stop after 120 minutes and must be deployed again
- Get the latest Runtime Tools for Ubuntu x86-64 (see below)
- Usage of Ubuntu/Ubuntu Server as the host machine is strongly recommended
- Open a terminal and execute
git clone [repo url]
replacing[repo url]
by the URL provided on this page or through the green "Code" button at the top right corner
- Go to the Factory Talk Hub page link
- Select the FactoryTalk® Optix™ tile
- Click to download the FactoryTalk® Optix™ Runtime Tools compatible with the FactoryTalk® Optix™ Studio you are going to use
- Select the Ubuntu Runtime Tools and download it
- Accept the user agreement and execute the downloader to get the Runtime Tools file
- Navigate to
C:\RA
, locate the downloaded file and uncompress it until you get to the.sh
file- Depending on the tools you used to decompress the archive, you may need to execute the operation once or twice to get to the
.sh
script
- Depending on the tools you used to decompress the archive, you may need to execute the operation once or twice to get to the
- You should get two
.sh
files, copy theFTOptixApplicationUpdateService.Ubuntu_22_x64.X.Y.Z.ZZZ.sh
to theUpdateServer
folder of this repository- The
FTOptixEntitlementCli.Ubuntu_22_x64.X.Y.Z.ZZZ.sh
can be ignored, it is not used in Docker containers
- The
- Open the terminal to the root of this repository
- Build the Docker container with the following command:
docker build . -t ftoptix-updateserver -f Docker/Dockerfile
root@ubuntu-VirtualBox:# docker build . -t ftoptix-updateserver -f Docker/Dockerfile
[+] Building 1.3s (21/21) FINISHED docker:default
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 1.41kB 0.0s
=> [internal] load metadata for docker.io/library/ubuntu:22.04 0.9s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> [ 1/16] FROM docker.io/library/ubuntu:22.04 0.0s
=> [internal] load build context 0.2s
=> => transferring context: 37.42MB 0.2s
=> DONE [ 2/16] ************ 0.0s
...
=> DONE [16/16] ************ 0.0s
=> exporting to image 0.0s
=> => exporting layers 0.0s
=> => writing image sha256:18eb........ 0.0s
=> => naming to docker.io/library/ftoptix-updateserver 0.0s
root@ubuntu-VirtualBox:#
- Verify the image was built with
docker images
root@ubuntu-VirtualBox:# docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
ftoptix-updateserver latest 18eba74533fb 1 minutes ago 355MB
root@ubuntu-VirtualBox:#
Now that the container is ready, we can execute it and deploy the FactoryTalk® Optix™ Application
In this example we will assume that the base image is called ftoptix-updateserver
, if you tagged the container with a different name, you may need to adapt the commands
- Execute in shell:
docker run -itd -p 49100:49100 -p 50080:80 -e FTOPTIX_ENTITLEMENT_SERIAL_NUMBER=AAAAA-BBBBB-CCCCC-DDDDD-EEEEE ftoptix-updateserver
- Make sure to insert a valid serial number in the environment variable
- Execute in shell:
docker run -itd -p 49100:49100 -p 50080:80 ftoptix-updateserver
- Without a proper license, the runtime will automatically stop after 120 minutes
- Execute the following command:
docker ps -a
root@ubuntu-VirtualBox:# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
************ ftoptix-updateserver "/opt/Rockwell_Autom…" 10 minutes ago Up 10 minutes 0.0.0.0:49100->49100/tcp, 0.0.0.0:50080->80/tcp, reverent_wilson
- Prepare your FactoryTalk® Optix™ Application by:
- Removing the NativePresentationEngine
- Configure the WebPresentationEngine
- Set the IP address to
0.0.0.0
(all addresses) - Set the Port to
80
(or any value you configured as an internal port of the container) - Set the Protocol to
http
- Set the IP address to
- Once the application is ready, configure the target with the proper IP Address and username and proceed with the deployment
- Proceed with the deployment
- Open the web browser and enter the URL:
http://<container_ip>:50080
- License is verified every 30 minutes
- If the FactoryTalk® Optix™ Application is stopped, the license is automatically released
- If the application crashes and the license is not released automatically to FT Hub, you may need to get in touch with the Rockwell Automation Software Tech Support
I passed a valid license to the container but the Runtime log says "No license tokens found, FactoryTalk Optix Runtime will be closed in: 120 minutes"
- Make sure that the license is valid
- Verify through FT Hub that the license is available to be used
- Verify that the size of the license is big enough to run the application (license tokens count >= application tokens count)
- Investigate the license SDK
- Open a shell prompt on the host machine
- Identify the container name with
docker ps -a
- Connect to the running container with
docker exec -it [container name] bash
- Browse to
/home/admin/Rockwell_Automation/FactoryTalk_Optix/FTOptixApplication/Log/FTOptixLicenseSDK/
- Inspect the
FTOptixLicenseSDK.log
- Here you should see the error (timeout, invalid license key, etc.)
- If there are issues that cannot be solved locally please get in touch with Rockwell Automation Software Tech Support
root@ubuntu-VirtualBox:# docker ps -a
ONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
dfaa01569c9c ftoptix-updateserver "/opt/Rockwell_Autom…" 37 seconds ago Up 36 seconds 0.0.0.0:49100->49100/tcp, :::49100->49100/tcp, 50080/tcp, 0.0.0.0:50080->80/tcp, :::50080->80/tcp jolly_hofstadter
root@ubuntu-VirtualBox:# docker exec -it jolly_hofstadter bash
root@dfaa01569c9c:~# cd /home/admin/Rockwell_Automation/FactoryTalk_Optix/FTOptixApplication/Log/FTOptixLicenseSDK/
root@dfaa01569c9c:~# cat FTOptixLicenseSDK.log
[2024-01-31 10:59:17.474] [LicenseSDK] [trace] [LicenseRepository] Called GetValidLicenses(product: Optix, component: Runtime)
[2024-01-31 10:59:17.475] [LicenseSDK] [trace] [GetValidLicenses] License storage contains 0 entitlement(s)
root@dfaa01569c9c:~#
- Access the FactoryTalk® Optix™ Application logs
- Open a shell prompt on the host machine
- Identify the container name with
docker ps -a
- Connect to the running container with
docker exec -it [container name] bash
- Browse to
/home/admin/Rockwell_Automation/FactoryTalk_Optix/FTOptixApplication/Log/
- Inspect the
FTOptixRuntime.0.log
- Contact Rockwell Automation Software Tech Support if needed
- Execute the container with:
docker run -itd -p 49100:49100 -p 50080:80 -e FTOPTIX_ENTITLEMENT_SERIAL_NUMBER=AAAAA-BBBBB-CCCCC-DDDDD-EEEEE --restart unless-stopped ftoptix-updateserver
How can I make the application folder persistent to avoid deploying my application every time the container starts?
- Run the container by binding the runtime app path (
/home/admin/Rockwell_Automation/FactoryTalk_Optix/FTOptixApplication
) to a folder on the host machine, for example:
root@ubuntu-VirtualBox:~# docker run -itd -p 49100:49100 -p 50080:80 -e FTOPTIX_ENTITLEMENT_SERIAL_NUMBER=AAAAA-BBBBB-CCCCC-DDDDD-EEEEE -v /home/ubuntu/Documents/FTOptix:/home/admin/Rockwell_Automation/FactoryTalk_Optix/FTOptixApplication ftoptix-updateserver
d0bd53d3ef******************************************
root@ubuntu-VirtualBox:~#
The UpdateServer will use the local machine's account to authenticate itself against the FactoryTalk Optix Studio. To change the deployment password you can:
-
Change the default password while creating the container:
- Open the Dockerfile
- Change the content of:
RUN echo "admin:FactoryTalkOptix" | chpasswd
, here you can replaceFactoryTalkOptix
with any valid password you wish
-
Change the default password of a running container
- Access the container's shell using:
docker exec -it [container name] bash
- Execute:
echo "admin:FactoryTalkOptix" | chpasswd
, here you can replaceFactoryTalkOptix
with any valid password you wish
- Access the container's shell using:
- Make sure the container is up and running
- Make sure the port 49100/TCP was exposed
- Make sure the container is reachable
- Make sure the proper user and password were used (default user is
admin
and the password isFactoryTalkOptix
)
- Make sure the license is marked as "Available" in FactoryTalk® Hub
- Make sure FactoryTalk® Optix™ version 1.4.0.450 or later was used
- Every FactoryTalk® Optix™ version comes with a specific UpdateServer version
- Make sure the right UpdateServer version was used