-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
22 changed files
with
1,329 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
build-oauth2: | ||
docker build --tag oauth2 -f oauth2/Dockerfile . | ||
|
||
build-websmtp: | ||
docker build --tag websmtp -f websmtp/Dockerfile . | ||
|
||
build-dashboard: | ||
docker build --tag dashboard -f dashboard/Dockerfile . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
{ | ||
"extends": "next/core-web-vitals" | ||
"extends": "next", | ||
"rules": { | ||
"react-hooks/rules-of-hooks": "off", | ||
"react/no-unescaped-entities": "off" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
FROM node:18-alpine AS base | ||
|
||
FROM base AS deps | ||
RUN apk add --no-cache libc6-compat | ||
WORKDIR /dashboard | ||
|
||
COPY dashboard/package.json dashboard/package-lock.json* ./ | ||
RUN npm ci | ||
|
||
FROM base AS builder | ||
WORKDIR /dashboard | ||
COPY --from=deps /dashboard/node_modules ./node_modules | ||
COPY dashboard . | ||
RUN npm run build | ||
|
||
FROM base AS runner | ||
WORKDIR /dashboard | ||
ENV NODE_ENV production | ||
ENV NEXT_TELEMETRY_DISABLED 1 | ||
RUN addgroup --system --gid 1001 nodejs | ||
RUN adduser --system --uid 1001 nextjs | ||
COPY --from=builder /dashboard/public ./public | ||
RUN mkdir .next | ||
RUN chown nextjs:nodejs .next | ||
COPY --from=builder --chown=nextjs:nodejs /dashboard/.next/standalone ./ | ||
COPY --from=builder --chown=nextjs:nodejs /dashboard/.next/static ./.next/static | ||
|
||
USER nextjs | ||
EXPOSE 3000 | ||
ENV PORT 3000 | ||
ENV HOSTNAME "0.0.0.0" | ||
|
||
CMD ["node", "server.js"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,4 @@ | ||
/** @type {import('next').NextConfig} */ | ||
module.exports = { | ||
async rewrites() { | ||
return [ | ||
{ | ||
source: '/auth/signup', | ||
destination: 'http://localhost:8080/auth/signup', | ||
}, | ||
{ | ||
source: '/auth/signin', | ||
destination: 'http://localhost:8080/auth/signin', | ||
}, | ||
{ | ||
source: '/auth/signout', | ||
destination: 'http://localhost:8080/auth/signout', | ||
}, | ||
{ | ||
source: '/auth/verify', | ||
destination: 'http://localhost:8080/auth/verify', | ||
}, | ||
{ | ||
source: '/auth/authorize', | ||
destination: 'http://localhost:8080/auth/authorize', | ||
}, | ||
{ | ||
source: '/auth/token', | ||
destination: 'http://localhost:8080/auth/token', | ||
}, | ||
{ | ||
source: '/client/:id', | ||
destination: 'http://localhost:8080/client/:id', | ||
}, | ||
{ | ||
source: '/client', | ||
destination: 'http://localhost:8080/client', | ||
}, | ||
{ | ||
source: '/user', | ||
destination: 'http://localhost:8080/user', | ||
}, | ||
] | ||
}, | ||
"output": 'standalone', | ||
} |
Oops, something went wrong.