Skip to content

Not able to changes default account id (000000000000) of cdklocal. #93

@bc-venkata-edara

Description

@bc-venkata-edara

I tried:

  1. I have tried adding export CDK_DEFAULT_ACCOUNT, but it did not picking up the account from the env, it still points to 000000000000.

  2. I was able to change the default region by doing aws configure, cdklocal synth --profile localstack, but aws configure doesn't accept account id.

Why I want to change default account id. we have account specific context in cdk.json, when we run cdklocal synth it's try to pickup account specifc context based on account id.

cdk.json:

{
"context": {
"account-id": {
"bucket-name": "test-dev"
},
"account-id2": {
"bucket-name": "test-dev"
}
}
}

app.py:

context = app.node.try_get_context(os.environ["CDK_DEFAULT_ACCOUNT"])

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions