</code></pre><h3id=docker-cli-click-here-for-more-info>docker cli (<ahref=https://docs.docker.com/engine/reference/commandline/cli/>click here for more info</a>)</h3><pre><codeclass=language-bash>docker run -d \
</code></pre><h2id=parameters>Parameters</h2><p>Docker images are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate <code><external>:<internal></code> respectively. For example, <code>-p 8080:80</code> would expose port <code>80</code> from inside the container to be accessible from the host's IP on port <code>8080</code> outside the container.</p><h3id=ports-p>Ports (<code>-p</code>)</h3><table><thead><tr><thalign=center>Parameter</th><th>Function</th></tr></thead><tbody><tr><tdalign=center><code>8000</code></td><td>will map the container's port 8000 to port 8000 on the host</td></tr></tbody></table><h3id=environment-variables-e>Environment Variables (<code>-e</code>)</h3><table><thead><tr><thalign=center>Env</th><th>Function</th></tr></thead><tbody><tr><tdalign=center><code>PUID=1000</code></td><td>for UserID - see below for explanation</td></tr><tr><tdalign=center><code>PGID=1000</code></td><td>for GroupID - see below for explanation</td></tr><tr><tdalign=center><code>TZ=<TZ></code></td><td>Timezone (i.e., America/New_York)</td></tr><tr><tdalign=center><code>SUPERUSER_EMAIL=<SUPERUSER_EMAIL></code></td><td>Email address for <code>admin</code> account</td></tr><tr><tdalign=center><code>SUPERUSER_PASSWORD=<SUPERUSER_PASSWORD></code></td><td>Password for <code>admin</code> account</td></tr><tr><tdalign=center><code>ALLOWED_HOST=<ALLOWED_HOST></code></td><td>The hostname you will use to access the app (i.e., netbox.example.com)</td></tr><tr><tdalign=center><code>DB_NAME=<DB_NAME></code></td><td>Database name (default: netbox)</td></tr><tr><tdalign=center><code>DB_USER=<DB_USER></code></td><td>Database user</td></tr><tr><tdalign=center><code>DB_PASSWORD=<DB_PASSWORD></code></td><td>Database password</td></tr><tr><tdalign=center><code>DB_HOST=<DB_HOST></code></td><td>Database host (default: postgres)</td></tr><tr><tdalign=center><code>DB_PORT=<DB_PORT></code></td><td>Database port (defaul: 5432)</td></tr><tr><tdalign=center><code>REDIS_HOST=<REDIS_HOST></code></td><td>Redis host (default: redis)</td></tr><tr><tdalign=center><code>REDIS_PORT=<REDIS_PORT></code></td><td>Redis port number (default: 6379)</td></tr><tr><tdalign=center><code>REDIS_PASSWORD=<REDIS_PASSWORD></code></td><td>Redis password (default: none)</td></tr><tr><tdalign=center><code>REDIS_DB_TASK=<REDIS_DB_TASK></code></td><td>Redis database ID for tasks (default: 0)</td></tr><tr><tdalign=center><code>REDIS_DB_CACHE=<REDIS_DB_CACHE></code></td><td>Redis database ID for caching (default: 1)</td></tr><tr><tdalign=center><code>BASE_PATH=<BASE_PATH></code></td><td>The path you will use to access the app (i.e., /netbox, optional, default: none)</td></tr><tr><tdalign=center><code>REMOTE_AUTH_ENABLED=<REMOTE_AUTH_ENABLED></code></td><td>Enable remote authentication (optional, default: False)</td></tr><tr><tdalign=center><code>REMOTE_AUTH_BACKEND=<REMOTE_AUTH_BACKEND></code></td><td>Python path to the custom Django authentication backend to use for external user authentication (optional, default: netbox.authentication.RemoteUserBackend)</td></tr><tr><tdalign=center><code>REMOTE_AUTH_HEADER=<REMOTE_AUTH_HEADER></code></td><td>Name of the HTTP header which informs NetBox of the currently authenticated user. (optional, default: HTTP_REMOTE_USER)</td></tr><tr><tdalign=center><code>REMOTE_AUTH_AUTO_CREATE_USER=<REMOTE_AUTH_AUTO_CREATE_USER></code></td><td>If true, NetBox will automatically create local accounts for users authenticated via a remote service (optional, default: False)</td></tr><tr><tdalign=center><code>REMOTE_AUTH_DEFAULT_GROUPS=<REMOTE_AUTH_DEFAULT_GROUPS></code></td><td>The list of groups to assign a new user account when created using remote authentication (optional, default: [])</td></tr><tr><tdalign=center><c
</code></pre><p>Will set the environment variable <code>PASSWORD</code> based on the contents of the <code>/run/secrets/mysecretpassword</code> file.</p><h2id=umask-for-running-applications>Umask for running applications</h2><p>For all of our images we provide the ability to override the default umask settings for services started within the containers using the optional <code>-e UMASK=022</code> setting. Keep in mind umask is not chmod it subtracts from permissions based on it's value it does not add. Please read up <ahref=https://en.wikipedia.org/wiki/Umask>here</a> before asking for support.</p><h2id=user-group-identifiers>User / Group Identifiers</h2><p>When using volumes (<code>-v</code> flags), permissions issues can arise between the host OS and the container, we avoid this issue by allowing you to specify the user <code>PUID</code> and group <code>PGID</code>.</p><p>Ensure any volume directories on the host are owned by the same user you specify and any permissions issues will vanish like magic.</p><p>In this instance <code>PUID=1000</code> and <code>PGID=1000</code>, to find yours use <code>id user</code> as below:</p><pre><codeclass=language-bash> $ id username