Выполняю установку согласно инструкции
docker-compose.yml заполнил согласно шаблона для postgre.
Однако после команды
docker compose up
получаю ошибку “Не удалось выполнить команду. Npgsql.PostgresException (0x80004005): 42P17: parameter “locale” must be specified”
Полный лог
root@static:/lers# docker compose up
[+] Running 2/2
⠿ Container lers-db-1 Recreated 0.1s
⠿ Container lers-lers-1 Recreated 0.1s
Attaching to lers-db-1, lers-lers-1
lers-db-1 |
lers-db-1 | PostgreSQL Database directory appears to contain a database; Skipping initialization
lers-db-1 |
lers-db-1 | 2022-11-01 20:21:15.358 UTC [1] LOG: starting PostgreSQL 15.0 (Debian 15.0-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
lers-db-1 | 2022-11-01 20:21:15.359 UTC [1] LOG: listening on IPv4 address “0.0.0.0”, port 5432
lers-db-1 | 2022-11-01 20:21:15.359 UTC [1] LOG: listening on IPv6 address “::”, port 5432
lers-db-1 | 2022-11-01 20:21:15.362 UTC [1] LOG: listening on Unix socket “/var/run/postgresql/.s.PGSQL.5432”
lers-db-1 | 2022-11-01 20:21:15.376 UTC [26] LOG: database system was shut down at 2022-11-01 20:20:11 UTC
lers-db-1 | 2022-11-01 20:21:15.400 UTC [1] LOG: database system is ready to accept connections
lers-lers-1 | I: Инициализация базы данных…
lers-lers-1 | I: Entity Framework Core 6.0.7 initialized ‘LersDbContext’ using provider ‘Npgsql.EntityFrameworkCore.PostgreSQL:6.0.5+9d79af6e2586d5d28da253ac075706a5575a1743’ with options: CommandTimeout=60 MigrationsAssembly=Lers.Dal.Migrations.Postgres
lers-lers-1 | I: Executed DbCommand (187ms) [Parameters=[], CommandType=‘Text’, CommandTimeout=‘60’]
lers-lers-1 | SELECT EXISTS (SELECT 1 FROM pg_catalog.pg_class c JOIN pg_catalog.pg_namespace n ON n.oid=c.relnamespace WHERE c.relname=‘__EFMigrationsHistory’);
lers-lers-1 | I: Executed DbCommand (5ms) [Parameters=[], CommandType=‘Text’, CommandTimeout=‘60’]
lers-lers-1 | SELECT EXISTS (SELECT 1 FROM pg_catalog.pg_class c JOIN pg_catalog.pg_namespace n ON n.oid=c.relnamespace WHERE c.relname=‘__EFMigrationsHistory’);
lers-lers-1 | I: Executed DbCommand (4ms) [Parameters=[], CommandType=‘Text’, CommandTimeout=‘60’]
lers-lers-1 | SELECT “MigrationId”, “ProductVersion”
lers-lers-1 | FROM “__EFMigrationsHistory”
lers-lers-1 | ORDER BY “MigrationId”;
lers-lers-1 | I: Applying migration ‘20220331054708_Initialize’.
lers-db-1 | 2022-11-01 20:21:27.706 UTC [31] ERROR: parameter “locale” must be specified
lers-db-1 | 2022-11-01 20:21:27.706 UTC [31] STATEMENT: CREATE COLLATION public.default_collation (LC_COLLATE = ‘ru-RU-u-ks-level2’,
lers-db-1 | LC_CTYPE = ‘ru-RU-u-ks-level2’,
lers-db-1 | PROVIDER = icu,
lers-db-1 | DETERMINISTIC = False
lers-db-1 | )
lers-lers-1 | E: Failed executing DbCommand (38ms) [Parameters=[], CommandType=‘Text’, CommandTimeout=‘60’]
lers-lers-1 | CREATE COLLATION public.default_collation (LC_COLLATE = ‘ru-RU-u-ks-level2’,
lers-lers-1 | LC_CTYPE = ‘ru-RU-u-ks-level2’,
lers-lers-1 | PROVIDER = icu,
lers-lers-1 | DETERMINISTIC = False
lers-lers-1 | );
lers-lers-1 | Не удалось выполнить команду. Npgsql.PostgresException (0x80004005): 42P17: parameter “locale” must be specified
lers-lers-1 | at Npgsql.Internal.NpgsqlConnector.g__ReadMessageLong|211_0(NpgsqlConnector connector, Boolean async, DataRowLoadingMode dataRowLoadingMode, Boolean readingNotifications, Boolean isReadingPrependedMessage)
lers-lers-1 | at Npgsql.NpgsqlDataReader.NextResult(Boolean async, Boolean isConsuming, CancellationToken cancellationToken)
lers-lers-1 | at Npgsql.NpgsqlDataReader.NextResult()
lers-lers-1 | at Npgsql.NpgsqlCommand.ExecuteReader(CommandBehavior behavior, Boolean async, CancellationToken cancellationToken)
lers-lers-1 | at Npgsql.NpgsqlCommand.ExecuteReader(CommandBehavior behavior, Boolean async, CancellationToken cancellationToken)
lers-lers-1 | at Npgsql.NpgsqlCommand.ExecuteNonQuery(Boolean async, CancellationToken cancellationToken)
lers-lers-1 | at Npgsql.NpgsqlCommand.ExecuteNonQuery()
lers-lers-1 | at Microsoft.EntityFrameworkCore.Storage.RelationalCommand.ExecuteNonQuery(RelationalCommandParameterObject parameterObject)
lers-lers-1 | at Microsoft.EntityFrameworkCore.Migrations.MigrationCommand.ExecuteNonQuery(IRelationalConnection connection, IReadOnlyDictionary2 parameterValues) lers-lers-1 | at Microsoft.EntityFrameworkCore.Migrations.Internal.MigrationCommandExecutor.ExecuteNonQuery(IEnumerable
1 migrationCommands, IRelationalConnection connection)
lers-lers-1 | at Microsoft.EntityFrameworkCore.Migrations.Internal.Migrator.Migrate(String targetMigration)
lers-lers-1 | at Lers.Server.CLI.DbUpdateHandler.HandleAsync() in C:\BuildAgent\work\4c5ff3b03c508a70\LersUchet\Server\Lers.Server\CLI\Handlers\DbUpdateHandler.cs:line 39
lers-lers-1 | at Lers.Server.CLI.CommandLineHandler.HandleAsync(String verb, IServiceProvider services) in C:\BuildAgent\work\4c5ff3b03c508a70\LersUchet\Server\Lers.Server\CLI\CommandLineHandler.cs:line 35
lers-lers-1 | Exception data:
lers-lers-1 | Severity: ERROR
lers-lers-1 | SqlState: 42P17
lers-lers-1 | MessageText: parameter “locale” must be specified
lers-lers-1 | File: collationcmds.c
lers-lers-1 | Line: 242
lers-lers-1 | Routine: DefineCollation
lers-lers-1 exited with code 255
Подскажите что я делаю не так?