Micke Alm
 · Head of User Experience at Steven, free-time builder/founder

Can't delete files from storage

I'm trying to get the delete data node to work so I can remove images from Firebase Storage, but something seems wrong with my permissions. Console shows: FirebaseError: [code=permission-denied]: Missing or insufficient permissions.

My rules in Firebase Storage are as follows:
rules_version = '2';
service firebase.storage {
match /b/{bucket}/o {
match /{allPaths=**} {
allow read, write: if request.auth.token.roles.size() > 0;
allow read, write: if false;
}
match /users/{userId}/{allPaths=**} {
allow read: if request.auth.uid == userId;
allow write: if request.auth.uid == userId;
allow delete: if request.auth.uid == userId;
}
}
}

I'm not quite sure where to keep looking… I can't see problems in the rules, not in the Delete Data node

Thanks for any help!

3 replies