nitro icon indicating copy to clipboard operation
nitro copied to clipboard

Database config shoud support use .env file

Open robin-dongbin opened this issue 11 months ago • 0 comments

Describe the feature

export default defineNitroConfig({
  database: {
    default: {
      connector: 'sqlite',
      options: { name: 'db' }
    },
    users: {
      connector: 'postgresql',
      url: 'postgresql://username:password@hostname:port/database_name'
    }
  }
})

Currently we define pgsql connection information in a configuration file. I think it's dangerous to expose connection information in config files

Additional information

  • [ ] Would you be willing to help implement this feature?

robin-dongbin avatar Mar 17 '24 11:03 robin-dongbin