• r

    rapid-raincoat-36492

    7 months ago
    Is creating resources inside an apply block acceptable? I did not think it was recommended, but I see it in an example in the docs here: https://www.pulumi.com/registry/packages/aws/api-docs/acm/certificatevalidation/
    r
    b
    5 replies
    Copy to Clipboard
  • q

    quick-fall-21011

    7 months ago
    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.
    Environment.SetEnvironmentVariable("KEYCLOAK_CLIENT_ID", "admin-cli");
    But seems the process can't access them, as it still complains that they're not set
    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?
    q
    e
    4 replies
    Copy to Clipboard
  • s

    stale-iron-26898

    7 months ago
    Hi all! I’m trying to setting up pulumi app with jenkins pipeline, I installed the pulumi github app in the organisation and jenkins job that run pulumi preview to the selected stack, but I cannot see any comments on the PR. Any ideas?
    s
    1 replies
    Copy to Clipboard
  • g

    gorgeous-minister-41131

    7 months ago
    is the Pulumi API having some issues today?
    p stack change-secrets-provider default
    Migrating old configuration and state to new secrets provider
    this is just… hanging.. I’m trying to migrate from a hashivault -> default provider .. the only thing I can think of is this stack has a lot of resources (200~) but it still shouldn’t take that long… edit: looks like the operation was extremely slow and adding
    -v
    flag didn’t really provide any additional info. Methinks it might be a useful to have…
    g
    o
    +1
    21 replies
    Copy to Clipboard
  • h

    helpful-account-44059

    7 months ago
    Hi, i'm using @plumi/awsx to create vpc, why the vpc i created not have the name ? i'm sure i have the name as the 1 position param
    h
    1 replies
    Copy to Clipboard
  • b

    bumpy-agent-19616

    7 months ago
    Hey guys, One quick question. How can we ensure the right order of creation of Pulumi components and their resources? Is it again dependsOn property from pulumi.ResourceOpts that needs to be used? I tried that but it is not working for some reason. Does anyone have any idea? A sample code could be found below,
    Namespace.ts
    -----------------
    export interface NamespaceArgs {
      name: string;
      metadata: {
        labels: {
          [key: string]: string;
        };
      };
    }
    
    export class Namespace extends pulumi.ComponentResource {
      constructor(
        name: string,
        args: NamespaceArgs,
        opts?: pulumi.CustomResourceOptions,
      ) {
        super(Constants.COMPONENT_TYPE, name, {}, opts);
    
        new k8s.core.v1.Namespace(
          args.name,
          {
            metadata: args.metadata,
          },
          {
            ...opts,
            parent: this,
          },
        );
      }
    }
    
    
    Secret.ts
    -----------------
    export interface SecretArgs {
      name: string;
      type: string;
      data: string;
      metadata: MetadataArgs;
    }
    
    export class Secret extends pulumi.ComponentResource {
      constructor(
        name: string,
        secretArgs: SecretArgs,
        opts?: pulumi.CustomResourceOptions,
      ) {
        super(Constants.COMPONENT_TYPE, name, {}, opts);
    
        const secretOpts = new SecretOpts();
        new k8s.core.v1.Secret(
          `${secretArgs.metadata.name}-${secretArgs.metadata.namespace}-${Constants.DEPLOYMENT}`,
          {
            data: secretOpts.setData(secretArgs.type, secretArgs.data),
            metadata: secretOpts.setMetadata(secretArgs.metadata),
            type: secretOpts.setType(secretArgs.type),
          },
          {
            ...opts,
            parent: this,
          },
        );
      }
    }
    
    IngressNginx.ts
    -----------------
    export interface IngressNginxArgs {
      helmVersion: HelmVersion.V2 | HelmVersion.V3;
      chartArgs: ChartArgs;
      namespaceArgs: NamespaceArgs;
      secretArgs: SecretArgs;
      provider: k8s.Provider;
    }
    
    export class IngressNginx extends pulumi.ComponentResource {
      constructor(
        name: string,
        ingressNginxArgs: IngressNginxArgs,
        opts?: pulumi.CustomResourceOptions,
      ) {
        super(Constants.COMPONENT_TYPE, name, {}, opts);
    
        const defaultResourceOpts: pulumi.ComponentResourceOptions = {
          parent: this,
          provider: ingressNginxArgs.provider,
        };
    
        const namespace = new Namespace(
          ingressNginxArgs.namespaceArgs.name,
          ingressNginxArgs.namespaceArgs,
          {
            ...defaultResourceOpts,
          },
        );
    
        const secret = new Secret(
          ingressNginxArgs.secretArgs.name,
          ingressNginxArgs.secretArgs,
          {
            ...defaultResourceOpts,
            dependsOn: [namespace],
          },
        );
    
        const ingressNginxResourceOpts: pulumi.ComponentResourceOptions = {
          ...defaultResourceOpts,
          dependsOn: [namespace, secret],
        };
        if (ingressNginxArgs.helmVersion == HelmVersion.V2) {
          new k8s.helm.v2.Chart(
            name,
            new IngressNginxChartOpts(ingressNginxArgs.chartArgs).setChartOpts(),
            ingressNginxResourceOpts,
          );
        } else {
          new k8s.helm.v3.Chart(
            name,
            new IngressNginxChartOpts(ingressNginxArgs.chartArgs).setChartOpts(),
            ingressNginxResourceOpts,
          );
        }
      }
    }
    b
    p
    +1
    33 replies
    Copy to Clipboard
  • e

    echoing-angle-67526

    7 months ago
    is there an estimate of when Pulumi 4.0 https://github.com/pulumi/pulumi/issues/7346 will be shipped? we're waiting on https://github.com/pulumi/pulumi/issues/2318 and it's been fixed but its listed as part of 4.0. will this feature be available before 4.0?
    e
    e
    +2
    7 replies
    Copy to Clipboard
  • f

    fancy-egg-38667

    7 months ago
    Trying to use GoLang version 1.18beta2 with Pulumi, getting the following error:
    error: failed to discover plugin requirements: parsing go version: Invalid character(s) found in minor number "18beta2"
    f
    n
    6 replies
    Copy to Clipboard
  • m

    mammoth-art-6111

    7 months ago
    getting a strange error when running
    pulumi import aws:codepipeline/pipeline:Pipeline
    :
    error: aws:codepipeline/pipeline:Pipeline resource 'staging-pipeline' has a problem: expected length of stage.0.action.0.namespace to be in the range (1 - 100), got . Examine values at 'Pipeline.Stages[0].Action[0].Namespace'.
    Looks like it's complaining that namespace isn't there, but that's an optional property?
    m
    e
    10 replies
    Copy to Clipboard
  • c

    cool-jewelry-33023

    7 months ago
    What's the process of changing the "ownership" of an organization? Do I just add a user as an admin, set myself as a member, and then the new admin kicks me out?
    c
    1 replies
    Copy to Clipboard