Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Firebase deploy could not locate firebase.json

so, im a newbie in programming and still learning some stuff (i use windows btw)

i try to make an app, connect it to firebase. after setting up everything its time to setting the CLI

good news : i successfully setting up everything from node to nvm untill sucessfully launch the login in CLI.

bad news : right after successfully logn the CLI, im trying to type in the cmd

firebase deploy --only function

and this error appear

Error: not in a Firebase app directory (could not locate firebase.json)

i already search the web for the solution but i found nothing

can someone tell me did i miss something ? thanks.

like image 335
Raymond Kristanto Avatar asked Oct 15 '18 16:10

Raymond Kristanto


People also ask

Where is firebase JSON?

Firebase automatically creates your firebase. json file at the root of your project directory when you run the firebase init command.

What script should be run before every deploy firebase?

To deploy resources from a project directory, the project directory must have a firebase. json file. This file is automatically created for you by the firebase init command.

Which command is used for deploying a firebase hosted application?

Using the Firebase CLI, you deploy files from local directories on your computer to our Hosting servers. Beyond serving static content, you can use Cloud Functions for Firebase or Cloud Run to serve dynamic content and host microservices on your sites.


1 Answers

After logging into firebase with "firebase login" you will need to do: "firebase init" and then select the correct options when prompted. be sure to press the space bar to check the functions circle in the command line.

like image 108
Kevin192291 Avatar answered Sep 18 '22 13:09

Kevin192291