mirror of
https://github.com/vapor/template-fluent-postgres.git
synced 2025-04-20 09:27:08 +08:00
Autogenerated from @451c5854622fb8117f08d95eefef26b216acea70
This commit is contained in:
parent
7b42d00a99
commit
decffaec0e
@ -8,7 +8,7 @@ public func configure(_ app: Application) async throws {
|
||||
// uncomment to serve files from /Public folder
|
||||
// app.middleware.use(FileMiddleware(publicDirectory: app.directory.publicDirectory))
|
||||
|
||||
app.databases.use(.postgres(configuration: SQLPostgresConfiguration(
|
||||
app.databases.use(DatabaseConfigurationFactory.postgres(configuration: .init(
|
||||
hostname: Environment.get("DATABASE_HOST") ?? "localhost",
|
||||
port: Environment.get("DATABASE_PORT").flatMap(Int.init(_:)) ?? SQLPostgresConfiguration.ianaPortNumber,
|
||||
username: Environment.get("DATABASE_USERNAME") ?? "vapor_username",
|
||||
|
Loading…
x
Reference in New Issue
Block a user