-
-
Notifications
You must be signed in to change notification settings - Fork 168
Description
I am considering adding custom types and providers to manage gitlab internal configs.
What is the best way to interact from a custom type/provider with gitlab?
At the moment I see two ways:
- executing gitlab-rails runner
- communicate with api
gitlab-rails command
The gitlab-rails command can be run as root user. No further authentication required.
This allows to check existing and add new tokens, users, groups, projects.
But: the command is very slow.
api
Communication with api needs a token.
root token can be managed using gitlab-rails only.
other user tokens can be managed using the root token.
all other resource types will need an autorequire on the gitlab_token type.
But: where to store the root api token itself so it can be used by all other resource types?
In puppet cache dir?
or is it possible to pass a variable from one provider to another one without again running the gitlab-rails command?