Thread
#automation-api
    m

    most-lighter-95902

    6 months ago
    const stack = await LocalWorkspace.selectStack({
      stackName: `${organization}/${stackName}`,
      projectName: project,
      program: async () => { }, // don't need a program just to get outputs
    })
    
    await stack.setAllConfig({ 'PULUMI_ACCESS_TOKEN': 'xxx' })
    
    const outputsRes = await stack.outputs()
    l

    little-cartoon-10569

    6 months ago
    PULUMI_ACCESS_TOKEN is an environment variable, not a conflg value.
    m

    most-lighter-95902

    6 months ago
    Hi @little-cartoon-10569 - thanks for the response. Is it secure to set PULUMI_ACCESS_TOKEN as an environment variable in a container?
    l

    little-cartoon-10569

    6 months ago
    I believe so. This approach is used with many tools as a secure way to avoid putting secret values on the command line. The environment of one shell / process is well-protected from other processes.
    This approach pre-dates Pulumi by many years...
    m

    most-lighter-95902

    6 months ago
    Got it thank you!