Open
Description
Users may want to deploy simple monitoring services without any authorization/authentication settings.
So, "Anonymous Auth" option with it's "Anonymous Organization Role" settings would be a useful and fast solution for that.
The GF_AUTH_ANONYMOUS_ENABLED
and GF_AUTH_ANONYMOUS_ORG_ROLE
container environment variables stands for them.
For the clarification of feature request, I'll share a rough code snippet for desired scenario.
GenericContainer<?> container =
new GenericContainer<>(ContainerUtils.getDockerImageName(properties))
.withEnv("GF_SECURITY_ADMIN_USER", properties.getUsername())
.withEnv("GF_SECURITY_ADMIN_PASSWORD", properties.getPassword())
//TODO: Anonymous Auth Configuration
.withEnv("GF_AUTH_ANONYMOUS_ENABLED", properties.getAnonymousAuthEnabled())
.withEnv("GF_AUTH_ANONYMOUS_ORG_ROLE", properties.getAnonymousOrgRole())
.withNetwork(Network.SHARED)
.withNetworkAliases(properties.getNetworkAlias(), GRAFANA_NETWORK_ALIAS)
.waitingFor(grafanaWaitStrategy);