I'm working on a project using Vapor 4 in Xcode.
However, when I try to run a simple initial migration, an error occurs:
[ WARNING ] PSQLError(code: server, serverInfo: [sqlState: 28000, file: miscinit.c, line: 798, message: role "vapor_username" does not exist, routine: InitializeSessionUserId, localizedSeverity: FATAL, severity: FATAL]) (App/entrypoint.swift:24) [ DEBUG ] Application shutting down (Vapor/Application.swift:306) Swift/ErrorType.swift:200: Fatal error: Error raised at top level: PSQLError(code: server, serverInfo: [sqlState: 28000, file: miscinit.c, line: 798, message: role "vapor_username" does not exist, routine: InitializeSessionUserId, localizedSeverity: FATAL, severity: FATAL])
So the message says:
"role "vapor_username" does not exist"
I have already started the server with the database using Docker, and it is running normally.
docker-compose up db
worked and the database was successfully launched.
What could be the problem?