skip to main content
Using an Environment File
Environment variables used to configure the agent can be supplied using a .env file. This pseudo-standard file format lists environment variables and their values separated by = and delimited by a newline. No other text including "shebangs," shell commands, # comments, etc., should appear in the file. For example:
ICE_AGENT_SERVER_URL=https://demo.icnow.app
ICE_AGENT_API_KEY=gu5hlp4glnf2qljh1xgiiu6vu475ga6pz4y69e5h75s5emlb2uro22mib4
ICE_AGENT_REFLECTOR_MULTICAST_INTERFACE=eth0
Apply an environment file using the --env-file command line argument. For example:
agent --env-file /path/to/my.env external reflector
When using Docker, passing a file from the host system to the agent is more complicated. The --mount or --volume switch to Docker is required to make the local environment file visible to the agent command inside Docker, for example:
docker run -v /path/to/:/app/local \
instantconnect/<ice-agent-image> \
--env-file /app/local/my.env