Perspective Client Hostname

If Ignition 8.1.10rc is running in a Docker Container, on windows, will it be able to resolve the client hostname?

Gateway configuration:

Session.props from a client

If you’re running your docker container with the default bridged network setup then all the connections are going to appear to come from the network gateway (172.17.0.1) and DNS resolution is not going to do anything for you here.

I also just noticed that the gateway setting does not survive a reboot.

Are you mounting/persisting the data directory?

Yes the data directory is mounted in a separate volume that is persisted. Other gateway settings changes survive reboot just fine. I just tested with Ignition installed on the host and the setting does survive reboots. It appears as if this is just an issue when installed in a container.

Ah, I did some digging, and it looks like that’s expected behavior. The thing to do is pass the resolveHostNames flag in as a container argument:

Docker image now supports passing arbitrary “gateway.*=” key/value pairs for the gateway.xml after the double-hyphen in the command args, similar to the existing capability for JVM/wrapper args.

So you would add gateway.resolveHostNames=true to the container.

Expected behavior for Docker only? Will the setting persist reboots on a VM?

Yes. It’s only necessary for Docker.

I just noticed that the data mount location is different in Inductive Automation’s images.

kcollins - /var/lib/ignition/data
IA - /usr/local/bin/ignition/data

After the ‘Resolve Client Hostnames’ is checked, I am still getting the IP address of my Client instead of the hostname in the session.props.host

Client hostname resolution is a reverse DNS operation on the IP address seen by the gateway, not a value passed from a client. Don’t expect client browsers to ever be trusted to do so.