5

I'd like to know that can "Firebase deploy" make update only for the sub directory inside root?

my structure

/public (index.html,other 100+ files)
/public/data (require.json) ::only 1 file

The problem is I need to update(deploy) only 1 file, "/public/data/require.json" about every hour. But when deploy, all data(& folders) inside public folder is updated and consuming too much cost.

Is there anyway to update only 1 specific folder or file inside webroot. Thank you.

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
Leonar Aung
  • 149
  • 1
  • 8

1 Answers1

4

The Firebase CLI can currently only deploy the entire web site. You cannot update a subset of the files.

It is a great feature request though and we've gotten it before. If you'd like to weigh in/cast your vote, I'd recommend you file a feature request.

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807
  • Understand it. Thank you. – Leonar Aung Apr 26 '18 at 15:33
  • wandering if there are any plans or work in progress on this? really need it as I'm working on SPA with multiple separated modules + website. Each of them has the "hosting" part but they all need to be managed and deployed separately. Currently I'm having a "master" project where each of the projects have to send their build output to and then deployed but it all must be orchestrated properly and be always kept in sync. Deploying to subdirectories would really simplify the process here and decouple the projects. – vir us Oct 08 '19 at 10:23
  • 1
    The CLI still behaves pretty much the same. But there's an API for Firebase Hosting nowadays, which allows you to build some things yourself, such as the single-file deploy that I mention in my answer here: https://stackoverflow.com/questions/34601488/can-i-add-additional-file-to-my-firebase-hosted-static-website-or-must-i-deploy/34601583#34601583 – Frank van Puffelen Oct 08 '19 at 12:50