Skip to content

[feat] module to import appropriate .env #2336

@heaths

Description

@heaths

It's great using azd to provision resources and being able to load the .env files using godotenv or whatever, but it would be even easier in projects using azd this way if we provided a library to make it easier e.g.,

func LoadEnv(env string) error {
    if env == "" {
        // get .azure/config@defaultEnvironment or err
    }
    // use godotenv to load environment's .env file,
    // optionally supporting fallback to/inclusion of any repo/ancestor .env file
}

It's not hard code to write, but any module support for azd (in Go or other languages) might help adoption.

Metadata

Metadata

Assignees

Labels

area/core-cliCLI commands, cmd/, internal/cmd/featureFeature requestneeds-discussionNeeds team discussion before proceeding

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions