db-migrate / node-db-migrate

Database migration framework for node
Other
2.32k stars 360 forks source link

'dev' environment not recognized after 'prod' migration - PostgreSQL #751

Open pzuluaga3 opened 3 years ago

pzuluaga3 commented 3 years ago

I'm submitting a...

Current behavior

After a 'production' migration in POSTGRESQL, db-migrate doesn't recognize local migration

database.json


{
    "defaultEnv": "dev",

    "dev": {
        "driver": "DB_DRIVER",
        "user": "DB_USER",
        "password": "DB_PASSWORD",
        "host": "DB_HOST",
        "database": "DB_NAME"
    },

    "prod": {
        "use_env_variable": "DATABASE_URL",
        "ssl": {
            "rejectUnauthorized": false
        }
    }
}

Errors

flisboac commented 2 years ago

Where in the docs is this use_env_variable property documented? Does it even work?

Also, I suppose driver, user, etc. are all taken literally, and are not supposed to be obtained from env-vars, right?