New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is there a way to load test data in docker? #5700
Comments
You can do that with blueprints, see https://goauthentik.io/developer-docs/blueprints/ for example the blueprint I use for some testing users: # yaml-language-server: $schema=https://goauthentik.io/blueprints/schema.json
version: 1
metadata:
name: local - dev users & groups
labels:
blueprints.goauthentik.io/instantiate: "false"
entries:
- model: authentik_core.group
identifiers:
name: Department foo
id: group_foo
- model: authentik_core.group
identifiers:
name: Department bar
id: group_bar
- model: authentik_core.group
identifiers:
name: Department baz
id: group_baz
- model: authentik_core.user
identifiers:
attributes:
managed: "user1"
attrs:
username: user1
name: user1
groups:
- !KeyOf group_foo
- model: authentik_core.user
identifiers:
attributes:
managed: "user2"
attrs:
username: user2
name: user2
groups:
- !KeyOf group_bar
- !KeyOf group_foo
- model: authentik_core.user
identifiers:
attributes:
managed: "user3"
attrs:
username: user3
name: user3
groups:
- !KeyOf group_baz
- !KeyOf group_bar
|
Thank you @BeryJu , Looks good, however is not clear to set the passwords - which seems to be a blocker |
Use case scenario context below:
|
It feels like something has been fixed but not released yet |
The PR above adds support to set user's passwords via blueprints, and will be released with 2023.6 (and also usable with the current beta version) |
Context:
I write an app (experiment with Spring boot service). For security I need an auth service. Ideally is to reuse an existing solution like Authentik. During the development phase I do write integration and system tests. Which means I need to run the auth service during those tests. For that a docker-compose was configured which looks to be fine for now.
Question:
Can I configure (or automate) authentik, so during docker start it would load few test users and an app credentials that I can use in tests?
Thanks
The text was updated successfully, but these errors were encountered: