How to deploy Firebase Bolt Rules

In my last we read about how to write Firebase Realtime Database Rules using Bolt. In this post, I will cover how you can deploy Bolt rules to Firebase realtime database.

Create a Firebase Project

Head over to Firebase Console and setup a project from there. Here are steps how you can create that: Click Here

Setup Firebase Tools on machine

Run the following command to install Firebase Tools on your machine globally:-

Firebase Init

Run firebase login to authenticate yourself in Firebase Tools. Once you are logged in, run firebase init which will display a wizard with options. You can choose Rules to deploy from the list and click ENTER for other options to leave them default.

Firebase Deploy

Run firebase deploy to deploy your Bolt Rules to Firebase.

Once you deploy it, you can test them either by going to Rule Emulator and run queries or using your Code.

Conclusion

We learnt about how to deploy Bolt Rules to Firebase using command line operation. Firebase is a realtime database largely loved and used by developers around the world.

1 thought on “How to deploy Firebase Bolt Rules

Leave a Reply

Your email address will not be published. Required fields are marked *