Skip to content

Commit

Permalink
More debug output
Browse files Browse the repository at this point in the history
  • Loading branch information
sbutz committed Dec 30, 2023
1 parent 404be1c commit d28e233
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/functions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,14 @@ jobs:
runs-on: ubuntu-latest
env:
working-directory: ./functions
GOOGLE_APPLICATION_CREDENTIALS: /opt/gcp_key.json
steps:
- uses: actions/checkout@v2
- name: Install Dependencies
run: npm ci
working-directory: ${{env.working-directory}}
- name: Export service account credentials to file
run: echo '${{ secrets.FIREBASE_SERVICE_ACCOUNT_POOLSCORE_1973 }}' > '${{ env.GOOGLE_APPLICATION_CREDENTIALS }}'
- name: Run Lint
run: npm run lint
working-directory: ${{env.working-directory}}
Expand Down
2 changes: 1 addition & 1 deletion functions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"predeploy": "npm run build",
"deploy": "npx firebase-tools deploy --force --only 'functions,extensions'",
"pretest": "npm run build",
"test": "npx firebase-tools emulators:exec 'npx jest --runInBand'",
"test": "npx firebase-tools emulators:exec --debug 'env; npx jest --runInBand'",
"test:watch": "concurrently --kill-others \"npm:build:watch\" \"npx firebase-tools emulators:exec 'npx jest --watch --runInBand'\""
},
"engines": {
Expand Down
3 changes: 3 additions & 0 deletions functions/src/firebase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ import {getStorage} from "firebase-admin/storage";
const config = process.env.FIREBASE_CONFIG ?
JSON.parse(process.env.FIREBASE_CONFIG) : undefined;

console.log(config);
console.log(process.env);

const app = initializeApp(config);
export const auth = getAuth(app);
export const storage = getStorage(app).bucket();
Expand Down

0 comments on commit d28e233

Please sign in to comment.