mattermost/server
Jesse Hallam 462f34ac6c
Generate default_roles_permissions.js from a live server snapshot (#36698)
* Generate default_roles_permissions.js from a live server snapshot

Replace the hand-maintained default_roles_permissions.js with a
generated file. The generator (scripts/default_permissions_generator/)
boots a real app.NewServer() against a temporary database created by
storetest.MakeSqlSettings, lets all schema and app-level migrations run
naturally, then snapshots the resulting Roles table into the JS file.

This eliminates the drift risk of the previous hand-maintained map:
new migrations are picked up automatically because the same server
initialization path is used here as in production.

The CI job gets a postgres service and sets IS_CI=true so the generator
uses the same host-switching logic as the rest of the test suite.
Locally, make start-docker provides the postgres instance.

* Address CodeRabbit feedback: pin checkout SHA, add permissions, add .PHONY entries
2026-05-25 15:03:11 -03:00
..
bin Mono repo -> Master (#22553) 2023-03-22 17:22:27 -04:00
build MM-68248: Support OpenSearch v3 (#36617) 2026-05-22 15:37:50 +00:00
channels MM-68663: Admin console support and Test Connection generalization for Azure Blob Storage (#36583) 2026-05-25 11:36:02 +00:00
cmd MM-68316: add mattermost db ping subcommand (#36406) 2026-05-21 18:46:52 +00:00
config MM-68663: Admin console support and Test Connection generalization for Azure Blob Storage (#36583) 2026-05-25 11:36:02 +00:00
einterfaces [MM-68400] Four plugin hooks and ChannelGuard enforcement (#36152) 2026-05-21 18:16:05 +00:00
enterprise MM-68248: Handle missing OpenSearch indexes gracefully before reindex (#36712) 2026-05-22 16:05:03 +00:00
fips MM-65959: Add FIPS indicator to about dialog (#34463) 2025-12-11 18:37:29 -04:00
fonts Mono repo -> Master (#22553) 2023-03-22 17:22:27 -04:00
i18n MM-68663: Admin console support and Test Connection generalization for Azure Blob Storage (#36583) 2026-05-25 11:36:02 +00:00
platform [MM-68400] Four plugin hooks and ChannelGuard enforcement (#36152) 2026-05-21 18:16:05 +00:00
public MM-68663: Admin console support and Test Connection generalization for Azure Blob Storage (#36583) 2026-05-25 11:36:02 +00:00
scripts Generate default_roles_permissions.js from a live server snapshot (#36698) 2026-05-25 15:03:11 -03:00
templates [MM-67859] Update license renewal and expiry email branding (#35701) 2026-04-04 20:30:36 -03:00
tests MM-68149: Upgrade to Go 1.26.2 (#36418) 2026-05-12 15:59:12 +00:00
.gitignore Update .server/gitignore to ignore all JSON files under the directory (#27593) 2024-07-11 09:12:57 +02:00
.go-version Upgrade Go to 1.26.3 (#36656) 2026-05-20 13:21:14 -03:00
.golangci.yml MM-68150: Upgrade golangci-lint to v2.12.2 (#36554) 2026-05-14 17:29:37 -04:00
.sass-lint.yml Mono repo -> Master (#22553) 2023-03-22 17:22:27 -04:00
AGENTS.md Add server/AGENTS.md (#35903) 2026-04-21 02:33:20 -07:00
config.mk Add Azurite to test infrastructure (#36485) 2026-05-11 12:06:59 +02:00
copyright.txt Mono repo -> Master (#22553) 2023-03-22 17:22:27 -04:00
docker-compose.makefile.yml Add Azurite to test infrastructure (#36485) 2026-05-11 12:06:59 +02:00
docker-compose.pgvector.yml Add pluggable AI actions menu with custom prompts extension point (#35930) 2026-04-14 18:46:20 +00:00
docker-compose.yaml MM-67668: Replace Promtail with OpenTelemetry collector (#35381) 2026-02-27 16:48:17 +01:00
go.mod MM-68151: Update server dependencies (#36571) 2026-05-20 18:20:19 -03:00
go.sum MM-68151: Update server dependencies (#36571) 2026-05-20 18:20:19 -03:00
Makefile Generate default_roles_permissions.js from a live server snapshot (#36698) 2026-05-25 15:03:11 -03:00
path.go Centralize the GetPackagePath (#27004) 2024-05-15 12:05:13 -03:00