I am currently working on a project that spins up several Inductive Automation Ignition 8.3.6 containers and makes use of the third party MQTT Transmission and MQTT Engine modules.
In previous version of Ignition the modules would be installed in /usr-lib but in 8.3 they are installed in */ignition/data/var/ignition/modl
I need to mount the volume to
/usr/local/bin/ignition/data
and the module need to be installed in
/usr/local/bin/ignition/data/var/ignition/modl/MQTTmodule.modl
Bellow is a screenshot of the /var/ignition directory.
When using a bind mount
- type: bind
source: ./gw-build/MQTT-Transmission-signed.modl
target: ${IGN_DATA}/var/ignition/modl/MQTT-Transmission-signed
the file mount as a directory and obfuscates the volume directories in Red but provides the path in Yellow. This leads to Ignition recognizing that a module is installed when hitting the Ignition gateway webpage and prompts me if i would like to use this module. It then fails to load the gateway web UI as those directories in red are require for the normal operation of Ignition.
Many Ignition forms and solution for this include running a docker build like this:
ARG IGNITION_VERSION
ARG MODULE
FROM inductiveautomation/ignition:${IGNITION_VERSION}
ARG MODULE
# for Ignition 8.1
COPY MQTT-Transmission-signed.modl /usr/local/bin/ignition/user-lib/modules/
# for Ignition 8.3
COPY ./MQTT-${MODULE}-signed.modl /usr/local/bin/ignition/data/var/ignition/modl/
However, in Ignition 8.3 the modules are not installed in /user-lib, and when it tries to copy the file it fails because the volume is not mounted and the */ignition/data/ directory does not exist.
As mentioned above, I have tried using a single file mount but, the file is seen as a directory even though the file exists in the host machine and the other required directories are obfuscated. However, I have discovered that If I exclude the .modl extension then it is mounted as a file and does not obfuscate the requisite directory but then Ignition does not see it as a module file.
I need to build an image based on Ignition, include the module file in a directory that does not depend on the volume mount then connect the volume mounted directory to the image stored file.
One thought was to symlink the file after the volume is mounted but it does not seem like you can create a symlink inside of docker compose.
How can I build an image that is not dependent on a volume but then gives a volume directory access to an image file?
OR
Can anyone tell me why the Ignition .modl extension is causing the binding error that obfuscates the /var/ingition/ directory to only have the /var/ignition/modl/ directory?
