https://pulumi.com logo
#general
Title
# general
q

quick-fall-21011

02/01/2022, 7:16 AM
Dear helpful community, I'm at a dead end with the https://github.com/pulumi/pulumi-keycloak resource provider. I'm creating my keycloak deployment as a helm chart in Project A, which saves the
keycloak:url
and
keycloak:password
as Stack Outputs. In Project B, I'd like to create a new Realm, and other related objects, however the login depends on these credentials being in Project B's config, or environment variables. I'd like it all to be automated, so although I can manually set the configuration in Project B, I'd like to avoid that. I tried the suggested alternative method, using Environment variables and setting them inside the project, e.g.
Copy code
Environment.SetEnvironmentVariable("KEYCLOAK_CLIENT_ID", "admin-cli");
But seems the process can't access them, as it still complains that they're not set
Copy code
Diagnostics:
  keycloak:index:Realm (pinostrats):
    error: 2 errors occurred:
        * missing required configuration key "keycloak:clientId":
    Set a value using the command `pulumi config set keycloak:clientId <value>`.
        * missing required configuration key "keycloak:url": The base URL of the Keycloak instance, before `/auth`
    Set a value using the command `pulumi config set keycloak:url <value>`.
Any ideas on how to get around this? Somehow manually instantiate the provider?
Ah.. hang on a second.. maybe I did just answer my own question... let me explore a little
e

echoing-dinner-19531

02/01/2022, 9:22 AM
Sounds like you want explicit providers and stack references
🙌 1
q

quick-fall-21011

02/04/2022, 5:09 AM
Sorry for the late reply. Got that sorted, thanks
🙌 1
17 Views