mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-30 14:39:29 +02:00
rename auth and start work separating config
This commit is contained in:
parent
deac897037
commit
d3bfac20a0
15 changed files with 153 additions and 120 deletions
|
@ -3,10 +3,11 @@ import { orgs } from "../db/schema";
|
|||
import config from "@server/config";
|
||||
import { ne } from "drizzle-orm";
|
||||
import logger from "@server/logger";
|
||||
import { extractBaseDomain } from "@server/utils/extractBaseDomain";
|
||||
|
||||
export async function copyInConfig() {
|
||||
// create a url from config.app.base_url and get the hostname
|
||||
const domain = new URL(config.app.base_url).hostname;
|
||||
const domain = extractBaseDomain(config.app.base_url);
|
||||
|
||||
// update the domain on all of the orgs where the domain is not equal to the new domain
|
||||
// TODO: eventually each org could have a unique domain that we do not want to overwrite, so this will be unnecessary
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue