Skip to content
Merged
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
6 changes: 4 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
NEXT_PUBLIC_URL="http://localhost:3000"
NEXT_PUBLIC_AXIOS_BASEPATH="/api/v1"

NEXT_TELEMETRY_DISABLED=1

REDIS_URL="redis://localhost:6379"

NODE_ENV="development"
Expand All @@ -22,12 +24,12 @@ AUTH_ALLOW_GOOGLE_DANGEROUS_EMAIL_ACCOUNT_LINKING="true"

EMAIL_SERVER_AUTH_USER="your-email@your-email-provider.tld"
EMAIL_SERVER_HOST="smtp.gmail.com"
//use 587 and secure false for unsecure
# use 587 and secure false for unsecure
EMAIL_SERVER_PORT=465
EMAIL_SERVER_SECURE=true
EMAIL_SERVER_AUTH_CLIENT_ID="id"
EMAIL_SERVER_AUTH_CLIENT_SECRET="secret"
EMAIL_SERVER_AUTH_REFRESH_TOKEN="token"
EMAIL_FROM="Authenticator <your-email@your-email-provider.tld>"
EMAIL_FROM="AuthForge <your-email@your-email-provider.tld>"

BCRYPT_HASH_ROUNDS=10
10 changes: 0 additions & 10 deletions .eslintrc.json

This file was deleted.

46 changes: 46 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: CI

on:
pull_request:
branches: [main]

jobs:
test:
runs-on: ubuntu-latest
env:
NEXT_TELEMETRY_DISABLED: 1

steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm

- name: Install dependencies
run: npm ci

- name: Use example env
run: cp .env.example .env

- name: Generate Prisma client
run: npx prisma generate

- name: Audit dependencies
run: npm audit --audit-level=high

- name: Format check
run: npm run format:check

- name: Lint
run: npm run lint

- name: Type check
run: npx tsc --noEmit

- name: Test
run: npm run test

- name: Build
run: npm run build
18 changes: 18 additions & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Release Please

on:
pull_request:
types: [closed]
branches: [main]

jobs:
release-please:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: googleapis/release-please-action@v4
with:
release-type: node
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npx lint-staged
1 change: 1 addition & 0 deletions .husky/pre-push
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
npm run format:check && npm run lint && npx tsc --noEmit && npm run test
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

FROM node:22-bookworm-slim AS base
WORKDIR /app
ENV NEXT_TELEMETRY_DISABLED=1
RUN apt-get update \
&& apt-get install -y --no-install-recommends python3 make g++ openssl ca-certificates \
&& rm -rf /var/lib/apt/lists/*
Expand Down
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2024-present Redouane Nouri

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading
Loading