feat: add MongoDB and Mongo Express services with initialization script
All checks were successful
Build and Push Docker Image / build (push) Successful in 1m41s

This commit is contained in:
2025-02-09 17:14:55 +01:00
parent 280a013c48
commit 76edbf0624
3 changed files with 87 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
db = db.getSiblingDB("statistics");
db.createRole({
role: "statsReadWrite",
privileges: [
{
resource: {
db: "statistics",
collection: "peertube",
},
actions: ["insert"],
},
],
roles: [
{
role: "read",
db: "statistics",
},
],
});
db.createUser({
user: "stats_user",
pwd: "@z^VFhN7q%vzit",
roles: [
{
role: 'statsReadWrite',
db: 'statistics',
},
],
});
db.createCollection("peertube");