Skip to content

Commit

Permalink
Update firebase rules
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilya Amursky committed Nov 17, 2023
1 parent 4dc038f commit 6700fa2
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 13 deletions.
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
.DS_Store
*.log
*.tsbuildinfo
/.firebase/
/.next/
/node_modules/
firebase-debug.log
next-env.d.ts
pnpm-debug.log*
service-account-key.json
25 changes: 24 additions & 1 deletion firebase.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@
},
"hosting": {
"source": ".",
"ignore": ["firebase.json", "**/.*", "**/node_modules/**"],
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
],
"frameworksBackend": {
"region": "us-central1",
"minInstances": 0,
Expand All @@ -15,5 +19,24 @@
},
"storage": {
"rules": "storage.rules"
},
"emulators": {
"auth": {
"port": 3001
},
"firestore": {
"port": 3002
},
"hosting": {
"port": 3000
},
"storage": {
"port": 3003
},
"ui": {
"enabled": true,
"port": 3030
},
"singleProjectMode": true
}
}
11 changes: 1 addition & 10 deletions firestore.rules
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,7 @@ rules_version = '2';
service cloud.firestore {
match /databases/{database}/documents {
match /{document=**} {
// This rule allows anyone with your database reference to view, edit,
// and delete all data in your database. It is useful for getting
// started, but it is configured to expire after 30 days because it
// leaves your app open to attackers. At that time, all client
// requests to your database will be denied.
//
// Make sure to write security rules for your app before that time, or
// else all client requests to your database will be denied until you
// update your rules.
allow read, write: if request.time < timestamp.date(2023, 12, 17);
allow read, write: if false;
}
}
}

0 comments on commit 6700fa2

Please sign in to comment.