Ansible install of Gitlab EE - how to create initial user?

All our services are installed and configured using Ansible. But I can’t see a clean way of setting up Gitlab’s first user, since seemingly the only way to create users is via a user’s API key. Chicken/egg.

Current kludgy idea is to go in though Rails and mess with the User table directly, but that’s the definition of a fragile solution.

There must be a way to bootstrap Gitlab headlessly, surely? I just need a way to get a working admin API key into the system so I can upload the licence, create the “real” users and then kill the first API key.

Anyone found a way? Thanks.

Terraform might help there.

Could this help?