mirror of
https://github.com/CompassConnections/Compass.git
synced 2026-04-04 14:53:33 -04:00
Make local DEV work out of the box
This commit is contained in:
@@ -1,22 +1,19 @@
|
||||
import { getLocalEnv, initAdmin } from 'shared/init-admin'
|
||||
import { getServiceAccountCredentials, loadSecretsToEnv } from 'common/secrets'
|
||||
import {
|
||||
createSupabaseDirectClient,
|
||||
type SupabaseDirectClient,
|
||||
} from 'shared/supabase/init'
|
||||
import {initAdmin} from 'shared/init-admin'
|
||||
import {loadSecretsToEnv} from 'common/secrets'
|
||||
import {createSupabaseDirectClient, type SupabaseDirectClient,} from 'shared/supabase/init'
|
||||
import {getServiceAccountCredentials} from "shared/firebase-utils";
|
||||
|
||||
initAdmin()
|
||||
|
||||
export const runScript = async (
|
||||
main: (services: { pg: SupabaseDirectClient }) => Promise<any> | any
|
||||
) => {
|
||||
const env = getLocalEnv()
|
||||
const credentials = getServiceAccountCredentials(env)
|
||||
const credentials = getServiceAccountCredentials()
|
||||
|
||||
await loadSecretsToEnv(credentials)
|
||||
|
||||
const pg = createSupabaseDirectClient()
|
||||
await main({ pg })
|
||||
await main({pg})
|
||||
|
||||
process.exit()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user