Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Description: Example of .env file
# Usage: Duplicate this file as .env and change as needed.

# MongoDB URI
MONGO_URI=mongodb://localhost:27017/example

# Auth Plugin
AUTH_DISCOVERY_URL=https://login.microsoftonline.com/c917f3e2-9322-4926-9bb3-daca730413ca/v2.0/.well-known/openid-configuration
AUTH_CLIENT_ID=b4bc4b9a-7162-44c5-bb50-fe935dce1f5a
AUTH_SKIP=false
12 changes: 6 additions & 6 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
nodeLinker: node-modules

plugins:
# Yarn plugin to enforce engine constraints
- checksum: e5e6e2885ab0e6521b70b0af7c6d8ca2c75dcae2403706fc4600a783b339a6530a476dafb9450c9436ca4050eb6bdee9b62e6e2cebfecf1e81dd709a2480dc07
path: .yarn/plugins/@yarnpkg/plugin-engines.cjs
spec: "https://raw.githubusercontent.com/devoto13/yarn-plugin-engines/main/bundles/%40yarnpkg/plugin-engines.js"

packageExtensions:
# commitlint does not configure its peer dependencies properly...
"@commitlint/load@*":
Expand All @@ -16,3 +10,9 @@ packageExtensions:
peerDependencies:
"typescript": "*"
"@types/node": "*"

plugins:
# Yarn plugin to enforce engine constraints
- checksum: e5e6e2885ab0e6521b70b0af7c6d8ca2c75dcae2403706fc4600a783b339a6530a476dafb9450c9436ca4050eb6bdee9b62e6e2cebfecf1e81dd709a2480dc07
path: .yarn/plugins/@yarnpkg/plugin-engines.cjs
spec: "https://raw.githubusercontent.com/devoto13/yarn-plugin-engines/main/bundles/%40yarnpkg/plugin-engines.js"
17 changes: 7 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@
"test": "tsx --test --experimental-test-coverage test/**/*.test.ts",
"compile": "tsgo --noEmit && tsgo -p test/tsconfig.json --noEmit",
"lint": "eslint --fix .",
"lint:file": "eslint --fix",
"lint:check": "eslint .",
"fmt": "prettier --write --list-different .",
"fmt:file": "prettier --write --ignore-unknown",
"fmt:check": "prettier --check .",
"build": "yarn clean && tsgo",
"start": "fastify start --log-level=info --options dist/src/app.js",
Expand All @@ -19,13 +21,11 @@
},
"lint-staged": {
"!(*.{js,ts})": [
"yarn fmt",
"git add"
"yarn fmt:file"
],
"*.{js,ts}": [
"yarn lint",
"yarn fmt",
"git add"
"yarn lint:file",
"yarn fmt:file"
]
},
"engines": {
Expand All @@ -46,9 +46,7 @@
"fastify-cli": "^7.4.1",
"fastify-metrics": "^12.1.0",
"fastify-plugin": "^5.1.0",
"jsonwebtoken": "^9.0.3",
"jwks-rsa": "^3.2.2",
"openid-client": "^6.8.2",
"jose": "^6.2.2",
"pino-loki": "^3.0.0",
"typebox": "~1.1.5"
},
Expand All @@ -57,7 +55,6 @@
"@commitlint/config-conventional": "^20.4.2",
"@eslint/js": "^9.39.2",
"@trivago/prettier-plugin-sort-imports": "^6.0.2",
"@types/jsonwebtoken": "^9.0.10",
"@types/node": "^25.3.0",
"@typescript/native-preview": "^7.0.0-dev.20260219.1",
"eslint": "^9.39.2",
Expand All @@ -72,5 +69,5 @@
"typescript": "^5.9.3",
"typescript-eslint": "^8.56.0"
},
"packageManager": "yarn@4.12.0+sha512.f45ab632439a67f8bc759bf32ead036a1f413287b9042726b7cc4818b7b49e14e9423ba49b18f9e06ea4941c1ad062385b1d8760a8d5091a1a31e5f6219afca8"
"packageManager": "yarn@4.13.0+sha512.5c20ba010c99815433e5c8453112165e673f1c7948d8d2b267f4b5e52097538658388ebc9f9580656d9b75c5cc996f990f611f99304a2197d4c56d21eea370e7"
}
3 changes: 1 addition & 2 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,6 @@ const options: AppOptions = {
pluginTimeout: 5 * 60 * 1000,

mongoUri: getOption("MONGO_URI")!,
authDiscoveryURL: getOption("AUTH_DISCOVERY_URL")!,
authClientID: getOption("AUTH_CLIENT_ID")!,
lokiHost: getOption("LOKI_HOST", false),
prometheusKey: getOption("PROMETHEUS_KEY", false),
authSkip: getBooleanOption("AUTH_SKIP", false),
Expand Down Expand Up @@ -210,6 +208,7 @@ const app: FastifyPluginAsync<AppOptions> = async (
// through your application
void fastify.register(AutoLoad, {
dir: path.join(__dirname, "plugins"),
ignorePattern: /(^|[\\/])auth\.ts$/,
options: opts,
forceESM: true,
});
Expand Down
Loading
Loading