-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
design changes and workflow updates --------- Co-authored-by: Ishan Sasanka <166486873+dmisasanka2002@users.noreply.github.com>
- Loading branch information
1 parent
de97955
commit 66efcc3
Showing
55 changed files
with
485 additions
and
334 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,15 @@ | ||
{ | ||
"projects": { | ||
"default": "firetest-c524f" | ||
} | ||
} | ||
"default": "rur-24" | ||
}, | ||
"targets": { | ||
"rur-24": { | ||
"hosting": { | ||
"rur25-official-web": [ | ||
"rur-24" | ||
] | ||
} | ||
} | ||
}, | ||
"etags": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Deploy Firebase Functions | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
types: | ||
- opened | ||
- synchronize | ||
|
||
jobs: | ||
build_and_deploy: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
|
||
- name: Install dependencies | ||
working-directory: functions | ||
run: npm install | ||
|
||
- name: Deploy to Firebase Functions | ||
env: | ||
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} | ||
run: | | ||
npm install -g firebase-tools | ||
firebase deploy --only functions --project rur-24 |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,56 +1,30 @@ | ||
# This file was auto-generated by the Firebase CLI | ||
# https://github.com/firebase/firebase-tools | ||
|
||
name: Deploy to Firebase Hosting on PR | ||
on: pull_request | ||
permissions: | ||
checks: write | ||
contents: read | ||
pull-requests: write | ||
|
||
jobs: | ||
build_and_preview: | ||
if: ${{ github.event.pull_request.head.repo.full_name == github.repository }} | ||
runs-on: ubuntu-latest | ||
env: | ||
env: # Set environment variables at the job level | ||
NEXT_PUBLIC_API_KEY: ${{ secrets.NEXT_PUBLIC_API_KEY }} | ||
NEXT_PUBLIC_AUTH_DOMAIN: ${{ secrets.NEXT_PUBLIC_AUTH_DOMAIN }} | ||
NEXT_PUBLIC_PROJECT_ID: ${{ secrets.NEXT_PUBLIC_PROJECT_ID }} | ||
NEXT_PUBLIC_STORAGE_BUCKET: ${{ secrets.NEXT_PUBLIC_STORAGE_BUCKET }} | ||
NEXT_PUBLIC_MESSAGING_SENDER_ID: ${{ secrets.NEXT_PUBLIC_MESSAGING_SENDER_ID }} | ||
NEXT_PUBLIC_APP_ID: ${{ secrets.NEXT_PUBLIC_APP_ID }} | ||
NEXT_PUBLIC_STATUS: ${{ secrets.NEXT_PUBLIC_STATUS }} | ||
FIREBASE_DEPLOY_TOKEN: ${{ secrets.FIREBASE_DEPLOY_TOKEN }} | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Cache dependencies | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
~/.npm # Cache global npm cache | ||
${{ github.workspace }}/.next/cache # Cache Next.js build cache | ||
${{ github.workspace }}/functions/node_modules # Cache Firebase Functions dependencies | ||
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }} | ||
restore-keys: | | ||
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}- | ||
- name: Install dependencies and build | ||
run: npm ci && npm run build | ||
|
||
- name: Deploy to Firebase Hosting | ||
uses: FirebaseExtended/action-hosting-deploy@v0 | ||
- uses: actions/checkout@v4 | ||
- run: npm ci && npm run build | ||
- uses: FirebaseExtended/action-hosting-deploy@v0 | ||
with: | ||
repoToken: ${{ secrets.GITHUB_TOKEN }} | ||
firebaseServiceAccount: ${{ secrets.FIREBASE_SERVICE_ACCOUNT_FIRETEST_C524F }} | ||
projectId: firetest-c524f | ||
|
||
- name: Install Firebase CLI | ||
run: npm install -g firebase-tools | ||
|
||
- name: Deploy Firebase Functions | ||
env: | ||
FIREBASE_TOKEN: ${{ secrets.FIREBASE_DEPLOY_TOKEN }} | ||
run: | | ||
cd functions | ||
npm ci | ||
firebase deploy --only functions --project firetest-c524f | ||
firebaseServiceAccount: ${{ secrets.FIREBASE_SERVICE_ACCOUNT_RUR_24 }} | ||
projectId: rur-24 | ||
target: rur25-official-web |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.