Skip to content

Commit

Permalink
Yeet unused ENV NEXTAUTH_URL (#109)
Browse files Browse the repository at this point in the history
  • Loading branch information
Yasamato authored Dec 8, 2024
1 parent 3da4865 commit 8c072d3
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 9 deletions.
1 change: 0 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ ENV CHROME_URL="ws://chrome:3000"
ENV NEXT_PUBLIC_SITE_NAME="The Anime Index"

# connection urls
ENV NEXTAUTH_URL="https://theindex.moe"
ENV NEXT_PUBLIC_DOMAIN="https://theindex.moe"
ENV AUTH_TRUST_HOST="true"
ENV DATABASE_URL="mongodb://mongo:27017/index"
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ Here is a collection of the possible environment variables with their default va
| ---------------------------- | ---------------------------------------------------------------------------------------------------- | ------------------------------------ |
| `NEXT_PUBLIC_SITE_NAME` | The name of your site | `"The Index"` |
| `NEXT_PUBLIC_DOMAIN` | Your domain or IP, remove trailing slash | `"https://theindex.moe"` |
| `NEXTAUTH_URL` | Your domain or IP, remove trailing slash | `$NEXT_PUBLIC_DOMAIN` |
| `DATABASE_URL` | Take a look at [mongodb docs](https://docs.mongodb.com/manual/reference/connection-string/) | `"mongodb://mongo:27017/index"` |
| `CACHE_URL` | Connection string for the redis cache database | `"redis://redis:6379"` |
| `CHROME_URL` | WebSocket URL to a running chrome instance | `"ws://chrome:3300"` |
Expand Down
1 change: 0 additions & 1 deletion auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { addUser } from './lib/db/users'
import { AccountType, type User } from './types/User'
import { MongoDBAdapter } from '@auth/mongodb-adapter'
import { dbClient } from './lib/db/db'
import { ObjectId } from 'mongodb'
import type { NextAuthConfig } from 'next-auth'
import { findOneTyped } from './lib/db/dbTyped'
import { Types } from './types/Components'
Expand Down
4 changes: 0 additions & 4 deletions cleanup.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,6 @@ if (!('NEXT_PUBLIC_DOMAIN' in process.env)) {
warnEnv('NEXT_PUBLIC_DOMAIN', 'https://theindex.moe')
}

if (!('NEXTAUTH_URL' in process.env)) {
warnEnv('NEXTAUTH_URL', 'https://theindex.moe')
}

if (!('DATABASE_URL' in process.env)) {
warnEnv('DATABASE_URL', 'mongodb://mongo:27017/index')
}
Expand Down
2 changes: 1 addition & 1 deletion components/data/DataItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ const DataItem: FC<Props> = ({ data, column, onChange }) => {
return <TextValue data={data || ''} column={column} onChange={onChange} />
}

console.error('Unknown type of column or data:', column, typeof data)
console.error('Unknown type of column or data:', column, typeof data, data)
return <div className={'alert alert-danger'}>Error: Unknown column type</div>
}

Expand Down
1 change: 0 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ services:
NEXT_PUBLIC_SITE_NAME: ${NEXT_PUBLIC_SITE_NAME}

# domain url for sessions
NEXTAUTH_URL: ${NEXTAUTH_URL}
NEXT_PUBLIC_DOMAIN: ${NEXT_PUBLIC_DOMAIN}
NEXTAUTH_SECRET: ${NEXTAUTH_SECRET}

Expand Down

0 comments on commit 8c072d3

Please sign in to comment.