Skip to content

Commit

Permalink
[⚙ : chore] Firebase Hosting
Browse files Browse the repository at this point in the history
  • Loading branch information
sryung1225 committed Dec 13, 2023
1 parent 1d657ff commit 54b59ba
Show file tree
Hide file tree
Showing 6 changed files with 65 additions and 1 deletion.
4 changes: 4 additions & 0 deletions .firebase/hosting.ZGlzdA.cache
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
logo.ico,1701433871282,37a4072cc6645faeccf408219d276c9de0736e566d6a65b06e7c0629abe53e76
index.html,1702458494045,e9cc563b3b01874b22db161a30b5edbe7c48170d3d9b2b30cc5c6a2b0f871a54
assets/logo-big-yB_EDFVs.png,1702458494045,b0c918f3c4bfc670ce24fde66f371827ca452fd24bc1e4adf2da9beda392c362
assets/index-BSVUOpMg.js,1702458494045,ed3f242cbc815ed6e24addd32bd3575b9d9f3d91ccf7feeea58b1241239a8bf3
5 changes: 5 additions & 0 deletions .firebaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"projects": {
"default": "xwitter-c64ef"
}
}
20 changes: 20 additions & 0 deletions .github/workflows/firebase-hosting-merge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# This file was auto-generated by the Firebase CLI
# https://github.com/firebase/firebase-tools

name: Deploy to Firebase Hosting on merge
'on':
push:
branches:
- main
jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm run build
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_XWITTER_C64EF }}'
channelId: live
projectId: xwitter-c64ef
17 changes: 17 additions & 0 deletions .github/workflows/firebase-hosting-pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# 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
jobs:
build_and_preview:
if: '${{ github.event.pull_request.head.repo.full_name == github.repository }}'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: npm run build
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: '${{ secrets.GITHUB_TOKEN }}'
firebaseServiceAccount: '${{ secrets.FIREBASE_SERVICE_ACCOUNT_XWITTER_C64EF }}'
projectId: xwitter-c64ef
16 changes: 16 additions & 0 deletions firebase.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"hosting": {
"public": "dist",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"rewrites": [
{
"source": "**",
"destination": "/index.html"
}
]
}
}
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
"dev": "vite",
"build": "tsc && vite build",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview"
"preview": "vite preview",
"predeploy": "npm run build",
"deploy": "firebase deploy"
},
"dependencies": {
"firebase": "^10.1.0",
Expand Down

0 comments on commit 54b59ba

Please sign in to comment.