# Ignition 8.1 Commissioning Automation

**URL:** <https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [June 21, 2022, 9:08pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034 "2022-06-21T21:08:02Z")\
**Posts on this page:** 15\
**Page:** 1

<div class="post-metadata">

**Author:** ![ralacosta](https://avatars.discourse-cdn.com/v4/letter/r/f0a364/32.png) [@ralacosta](https://forum.inductiveautomation.com/u/ralacosta)\
**Post date:** [June 21, 2022, 9:08pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/1 "2022-06-21T21:08:02Z")

</div>

Has anyone been able to use a custom hash for the commissioning file when installing 8.1? Currently we use the modifications outlined here: [ZIP File Installations - Ignition User Manual 8.1 - Ignition Documentation](https://docs.inductiveautomation.com/display/DOC81/ZIP+File+Installations).

```auto
{
  "isCommissioned": "COMMISSIONING",
  "connections.useSsl": "false",
  "eulaSetup.accepted": "true",
  "eulaSetup.eula": "TuLW3I1yHBlo9kuqbxz5cDFPf5H4/zqSpbO93Tk7Hco=",
  "authSetup.username": "admin",
  "authSetup.password": "[e811cfc7]fc3b28ad5f73331c94790129f0931437ac31d59376b0e4b15df580a8841ba165"
}

```

This sets the password to the default, which is great, but I was looking to put our custom password in there instead.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [June 21, 2022, 9:21pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/2 "2022-06-21T21:21:41Z")

</div>

@Kevin.Collins reverse-engineered it (before he was hired) and has a bash snippet available that he uses in his docker images.

> <https://github.com/thirdgen88/ignition-docker/blob/main/8.1/perform-commissioning.sh#L96>

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [June 22, 2022, 2:32pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/3 "2022-06-22T14:32:11Z")

</div>

I’ll add that you can use the same environment variables within a regular installation that you’d use for auto-commissioning a Docker container. Setting these vars will satisfy commissioning and continue with Gateway startup automatically:

- `IGNITION_EDITION=standard`
- `GATEWAY_ADMIN_PASSWORD=password`
- `ACCEPT_IGNITION_EULA=Y`
- `GATEWAY_DEFAULT_PORTS=true`

Alternatively, you can also specify all the individual ports:

- `GATEWAY_HTTP_PORT=8088`
- `GATEWAY_HTTPS_PORT=8043`
- `GATEWAY_GAN_PORT=8060`

A couple other bonus tips:

- You can also specify `GATEWAY_ADMIN_PASSWORD_FILE=/path/to/file` where the contents of the file feed the environment variable.
- The final value of `GATEWAY_ADMIN_PASSWORD` (whether directly or by file) can also be a salted hash (created using the code Paul posted above) instead of an explicit password.

Seeding the commissioning file directly is also perfectly valid, but I wanted to mention this in the event that it wasn’t known that these particular environment variables were actually integrated into the platform itself for 8.1.9+ (and not just part of our Docker image entrypoint logic).

---

<div class="post-metadata">

**Author:** ![ralacosta](https://avatars.discourse-cdn.com/v4/letter/r/f0a364/32.png) [@ralacosta](https://forum.inductiveautomation.com/u/ralacosta)\
**Post date:** [June 22, 2022, 7:43pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/4 "2022-06-22T19:43:28Z")

</div>

> [@kcollins](#):
>
> IGNITION\_EDITION=standard

Thanks for all the tips. We're not using Docker images, which is why we opted to seed the commissioning file. I did try to seed the commissioning file on an upgrade of 7.9 to 8.1, with the admin password. A temp user source, like when resetting the password using the gwcmd was created with the new admin user.

The GitHub repo was great and it's very helpful to be able to input our own hash in this way during commissioning to automate some of this. This didn't help much in the upgrade of 7.9 to 8.1 though because of the mentioned temp user source that was created.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [June 22, 2022, 7:51pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/5 "2022-06-22T19:51:32Z")

</div>

> [@ralacosta](#):
>
> I did try to seed the commissioning file on an upgrade of 7.9 to 8.1, with the admin password. A temp user source, like when resetting the password using the gwcmd was created with the new admin user.

IIRC, you shouldn't need to define a password during commissioning on an upgrade from 7.9 to 8.x (and doing so will perform a password reset, as you note).

---

<div class="post-metadata">

**Author:** ![ralacosta](https://avatars.discourse-cdn.com/v4/letter/r/f0a364/32.png) [@ralacosta](https://forum.inductiveautomation.com/u/ralacosta)\
**Post date:** [June 22, 2022, 8:09pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/6 "2022-06-22T20:09:20Z")

</div>

Yes. That’s correct. No need to enter a new user/password into there.

The EULA does make a return though, which is what we were able to skip through on initial deployment by seeding the commissioning.json file.

I was looking to see if there was a way to skip the EULA in the same way. I had tested this without setting up the user and password in the commissioning file, and a new user was requested in the EULA prompt also. The provided Github repo solution uses curl and basically accepts the EULA that way.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [June 22, 2022, 8:56pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/7 "2022-06-22T20:56:12Z")

</div>

> [@ralacosta](#):
>
> I was looking to see if there was a way to skip the EULA in the same way. The provided Github repo solution uses curl and basically accepts the EULA that way.

Ahhh, I see.. Yes, it would be easiest to just add the `ACCEPT_IGNITION_EULA=Y` var to your environment then.. If you're on Linux, see an example below for updating the systemd override file with additional environment variables:

[https://asciinema.org/a/KnHcZHFOxr5cPNkOR4BkEPnNO](https://asciinema.org/a/KnHcZHFOxr5cPNkOR4BkEPnNO)

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [June 27, 2022, 3:45pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/8 "2022-06-27T15:45:31Z")

</div>

I put together a quick video to demonstrate an installation and then upgrade from Ignition 7.9.20 to Ignition 8.1.18 with the systemd overrides. Along the way I add some audio insight–hopefully this helps with folks who might be interested in this solution for helping automate upgrades.

[forum-61034.mp4](https://inductiveautomation1-my.sharepoint.com/:v:/g/personal/kcollins_inductiveautomation_com/EUuOlEkLSWFMvpO6QMIkbmUBClhoWvv1jNobzeO9LUGHvg?e=cFnPwD)

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [June 30, 2022, 12:57pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/9 "2022-06-30T12:57:55Z")

</div>

Another supplement here, this script can be used to generate a salted SHA256 hash of a password for direct use within `GATEWAY_ADMIN_PASSWORD` environment variable or the `commissioning.json` file:

> <https://gist.github.com/thirdgen88/c4257bd4c47b6cc7194d1f5e7cbd6444>

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [October 19, 2022, 7:32pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/10 "2022-10-19T19:32:08Z")

</div>

> [@kcollins](#):
>
> Setting these vars will satisfy commissioning and continue with Gateway startup automatically

Hmm. Doesn't seem to work with executable installers. I was hoping to switch away from the zip installs.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [October 19, 2022, 7:36pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/11 "2022-10-19T19:36:50Z")

</div>

Is your expectation/wish that these environment variables will be discovered by the executable installer and applied to the underlying service configuration as part of the installation?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [October 19, 2022, 7:38pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/12 "2022-10-19T19:38:29Z")

</div>

Yes. Particularly for unattended installs. I'm working up an auto-install for netboot/minimal ISO kits.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [October 19, 2022, 7:39pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/13 "2022-10-19T19:39:35Z")

</div>

Gotcha.. I could see that being handy..

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [October 19, 2022, 8:08pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/14 "2022-10-19T20:08:00Z")

</div>

Succeeded with a work-around using a SystemD drop-in. Just before invoking the installer, my script has this:

```bash
mkdir -p /etc/systemd/system/ignition.service.d
cat >/etc/systemd/system/ignition.service.d/override.conf <<EOF
[Service]
AmbientCapabilities=CAP_NET_BIND_SERVICE CAP_NET_RAW
Environment=ACCEPT_IGNITION_EULA=Y
Environment=GATEWAY_ADMIN_USERNAME=someUserName
Environment=GATEWAY_ADMIN_PASSWORD=somePassword
Environment=IGNITION_EDITION=edge
Environment=GATEWAY_HTTP_PORT=80
Environment=GATEWAY_HTTPS_PORT=443
Environment=GATEWAY_GAN_PORT=8060
EOF

```

The installer launches like so:

```bash
useradd -c "Ignition Service" -U -m -G dialout ignition
"./$installer" -- unattended=text logLevel=debug user=ignition serviceName=ignition location=/usr/share/ignition

```

After the installer completes, I have this in the script:

```bash
cat >/etc/systemd/system/ignition.service.d/override.conf <<EOF
[Service]
AmbientCapabilities=CAP_NET_BIND_SERVICE CAP_NET_RAW
EOF

systemctl daemon-reload

```

This booted all the way up into Edge on ports 80 & 443 while running non-root. (:

Edit: I messed up the password hash somehow. But a plain password works.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [October 19, 2022, 10:29pm UTC](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/15 "2022-10-19T22:29:40Z")

</div>

> [@pturmel](#):
>
> Succeeded with a work-around using a SystemD drop-in.

Nice. Yeah, I suppose there is nothing wrong with pre-loading the systemd service overrides to have the env vars be there when the installer starts up the service.

> [@pturmel](#):
>
> Edit: I messed up the password hash somehow. But a plain password works.

The gist I linked above ([here](https://forum.inductiveautomation.com/t/ignition-8-1-commissioning-automation/61034/9)) should help you generate a valid hash for the env var.
