Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Rename NEXTAUTH_URL as it is no longer required for Next-Auth #3288

Merged
merged 1 commit into from
Feb 27, 2024
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
1 change: 0 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ LOCAL_AWS_ENDPOINT=http://127.0.0.1:4566

AWS_ACCESS_KEY_ID=foo
AWS_SECRET_ACCESS_KEY=bar
NEXTAUTH_URL=http://localhost:3000
REDIS_URL=redis
LOCAL_LAMBDA_ENDPOINT=http://host.docker.internal:3001
RELIABILITY_FILE_STORAGE=forms-local-reliability-file-storage
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- 6379:6379
env:
# Needed for Next Auth to initialize
NEXTAUTH_URL: http://localhost:3000
HOST_URL: http://localhost:3000
TOKEN_SECRET: testKey
APP_ENV: test
REDIS_URL: localhost
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ SUBMISSION_API=Submission
TEMPLATES_API=Templates
AWS_ACCESS_KEY_ID= // ask the dev team
AWS_SECRET_ACCESS_KEY= // ask the dev team
NEXTAUTH_URL=http://localhost:3000
HOST_URL=http://localhost:3000
REDIS_URL=localhost
```

Expand Down Expand Up @@ -186,7 +186,7 @@ SUBMISSION_API=Submission
TEMPLATES_API=Templates
AWS_ACCESS_KEY_ID= // Can be found in LastPass
AWS_SECRET_ACCESS_KEY= // Can be found in LastPass
NEXTAUTH_URL=http://localhost:3000
HOST_URL=http://localhost:3000
REDIS_URL=localhost
```

Expand Down
2 changes: 1 addition & 1 deletion lib/auth/passwordReset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ const sendPasswordResetEmail = async (email: string, token: string) => {
try {
const notify = getNotifyInstance();

const baseUrl = process.env.NEXTAUTH_URL;
const baseUrl = process.env.HOST_URL;

await notify.sendEmail(process.env.TEMPLATE_ID, email, {
personalisation: {
Expand Down
2 changes: 1 addition & 1 deletion lib/deactivate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { logMessage } from "@lib/logger";

export const sendDeactivationEmail = async (email: string) => {
try {
const HOST = process.env.NEXTAUTH_URL;
const HOST = process.env.HOST_URL;
const TEMPLATE_ID = process.env.TEMPLATE_ID;
const notify = getNotifyInstance();

Expand Down
2 changes: 1 addition & 1 deletion lib/integration/freshdesk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export const formatTicketData = ({
description,
language,
}: createTicketProps) => {
const HOST = process.env.NEXTAUTH_URL || "";
const HOST = process.env.HOST_URL || "";
const hostTag = tagHost(HOST);

const ticket = {
Expand Down
4 changes: 2 additions & 2 deletions lib/ownership.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const transferOwnershipEmail = async ({
formId: string;
}) => {
try {
const HOST = process.env.NEXTAUTH_URL;
const HOST = process.env.HOST_URL;
const TEMPLATE_ID = process.env.TEMPLATE_ID;
const notify = getNotifyInstance();

Expand Down Expand Up @@ -79,7 +79,7 @@ export const addOwnershipEmail = async ({
formId: string;
}) => {
try {
const HOST = process.env.NEXTAUTH_URL;
const HOST = process.env.HOST_URL;
const TEMPLATE_ID = process.env.TEMPLATE_ID;
const notify = getNotifyInstance();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const CopyCodes = ({
}) => {
const { t } = customTranslate("my-forms");
const capitalizedLang = lang === "en" ? "En" : "Fr";
const HOST = process.env.NEXTAUTH_URL || "";
const HOST = process.env.HOST_URL || "";

return (
<div className="flex flex-row">
Expand Down
Loading