Firebase Storage Error code:400

eesope·2021년 11월 21일
0

App Basic @SCC

목록 보기
1/5
post-thumbnail

파이어베이스 스토리지에 파일 업로드 시도 -> 에러

에러 당시 상태:

  • Storage rule
rules_version = '2';
service firebase.storage {
  match /b/{bucket}/o {
    match /{allPaths=**} {
      allow read, write: if request.auth != null;
    }
  }
}
  • Error Code
{
error: {
code: 400,
message: "Permission denied. Please enable Firebase Storage for your bucket by visiting the Storage tab in the Firebase Console and ensure that you have sufficient permission to properly provision resources."
}
}

해결 후 상태:

  • Storage rule
service firebase.storage {
  match /b/{bucket}/o {
    match /{allPaths=**} {
      allow read, write: if request.auth != null;
    }
  }
}

Stack Overflow 참고하여
파이어베이스 console IAM & Admin 에 "Storage Admin" role 으로
firebase-storage@system.gserviceaccount.com
를 추가했니 파일 업로드 성공

profile
go simple 🧑🏻‍💻

0개의 댓글

관련 채용 정보