I have a .gcloudignore
but still keep getting the error:
Your proposed upload is larger than the maximum
Is there any way to see which files will be deployed or otherwise debug this?
A bit like git add . -n
since it takes 10mins to try a full deploy process.
I have a layout like below.
- I've tried placing the
.gcloudignore
at the top level and also inside the functions dir. - I've tried deploying from both within 'functions' and also from the top level.
- made sure the gcloudignore ALSO will ignore everything in
.gitignore
by using the special directive. - made sure the
.gitignore
is available at the same level as.gcloudignore
- checked the
enabled
status of the.gcloudignore
But it still doesn't work and is preventing deployment.
├── cloud_tasks_emulator
│ └── docker-compose.yaml
├── firebase-debug.log
├── firebase.json
├── firestore.indexes.json
├── firestore.rules
├── functions
│ ├── lib/ <== compiled ts>js output
│ ├── node_modules
│ ├── package-lock.json
│ ├── package.json
│ ├── renders/ <== this local folder i'm trying to ignore
│ ├── src/ <== also i dont really want .ts src deployed
│ └── yarn.lock
├── justfile
├── package-lock.json
├── package.json
└── storage.rules
And the .gcloudignore
looks like this
# files to not upload to gcloud
# include the gitignore also https://cloud.google.com/sdk/gcloud/reference/topic/gcloudignore
#!include:.gitignore
.gcloudignore
.git
.gitignore
renders
functions/renders
renders/
links / related
Seems like
.gcloudignore
file is meant for onlyGCP
deployment, not forfirebase
deployments. As there are no commands related to firebase in the documentation that you shared, onlygcloud
commands respect the.gcloudignore
file. Hence, the files are not ignored infirebase deploy
.To ignore files on
firebase
deployment, you may useignore
field in thefirebase.json
file as discussed here.To see which files will be deployed, try ListFiles endpoint, which will list remaining files to be uploaded for the specified version.