Allow emulators to export on exit
See original GitHub issueOriginally requested through FIrebase support, there is some demand for a flag like this:
firebase emulators:start --import=./seed --export-on-exit
This would import from a location but save any mutations made on exit.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:12
- Comments:19 (12 by maintainers)
Top Results From Across the Web
Firebase Emulator --export-on-exit not working properly ...
Same issue today but on mac. I'm using firebase-tools version 10.7.0. The work around I'm using is to manually run firebase emulators:export ./ ......
Read more >Install, configure and integrate Local Emulator Suite - Firebase
Instruct the emulator(s) to export data to a directory when shutdown occurs, as described for the emulators:export command. The export directory can be ......
Read more >How to persist your data with Firebase Emulators - Medium
So to make our life's super easy, simply use the CLI command firebase emulators:start --import <export-directory> --export-on-exit ...
Read more >Persisting Data on Firebase Emulator - Mukhthar CM
Even though Firebase Emulators Don't have something like Saving Data, Luckily, they Can Export and Import Data. Let's dig into it.
Read more >Firebase Emulators (Legacy) | OneArmy Community Platform
This can be achieved by passing the --export-on-exit=. ... By default emulators allow full read/write access to all resources, however firebase functions ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@michi88 thanks for asking all the right questions. My personal take:
I like the name
--export-on-exit
I think it should take an optional path
--export-on-exit=./some-path
. When unspecified it would use the same path as--import
. If you do a bare--export-on-exit
with no--import=something
flag that’s an error. So:emulators:start --import=./foo --export-on-exit
emulators:start --import=./foo --export-on-exit=./bar
emulators:start --export-on-exit=./bar
emulators:start --export-on-exit
If that sounds good to you I’ll propose it to the API people.
Waiting with anticipation. I didn’t realise that data was not saved automatically after restarting and was wondering what was wrong with my app until I checked the db, I’m glad I’m not crazy.