Skip to content

Check ExampleEnvironmentVariablesAreSet doesn't check actual environment variables #83

Open
@rick-nu

Description

@rick-nu

What

The check ExampleEnvironmentVariablesAreSet only compares the .env.example with the .env file. It would make sense to check if actual environment variables are set too.

Why

We're running a laravel project in Kubernetes. In the production container there is no .env file, but instead the environment variables are set on the container directly. We want to run the ExampleEnvironmentVariablesAreSet as "init container" to be sure that the container doesn't start with missing environment variables.

Proposed fix

Also check the actual environment variables (getenv()), don't just compare the .env file.

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