Skip to content

Commit

Permalink
fix: only display azure login if not empty string
Browse files Browse the repository at this point in the history
  • Loading branch information
rschlaefli committed Sep 20, 2023
1 parent 9102415 commit 0bfcd11
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ WORKDIR /app
COPY --from=deps /app/node_modules ./node_modules
COPY . .

ARG NODE_ENV production
ARG NODE_ENV stage
# Next.js collects completely anonymous telemetry data about general usage.
# Learn more here: https://nextjs.org/telemetry
# Uncomment the following line in case you want to disable telemetry during the build.
Expand All @@ -29,7 +29,7 @@ RUN npm run build
FROM node:18.12.0-alpine AS runner
WORKDIR /app

ARG NODE_ENV production
ARG NODE_ENV stage
# Uncomment the following line in case you want to disable telemetry during runtime.
# ENV NEXT_TELEMETRY_DISABLED 1

Expand Down
1 change: 1 addition & 0 deletions src/lib/authOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ export const authOptions: NextAuthOptions = {
// from: process.env.EMAIL_FROM,
// }),
typeof process.env.AZURE_AD_CLIENT_ID === 'string' &&
process.env.AZURE_AD_CLIENT_ID !== '' &&
AzureADProvider({
clientId: process.env.AZURE_AD_CLIENT_ID as string,
clientSecret: process.env.AZURE_AD_CLIENT_SECRET as string,
Expand Down

0 comments on commit 0bfcd11

Please sign in to comment.