When running firebase deploy --only functions the file lib/index.js is never updated and keeps the old version. Any idea why?
It worked the first time, but the first version of the file is kept and it never updates anymore...
Thanks!
I had the same issue (although using typescript), in my case what happened was:
I added external dependencies in the tsconfig.json, such as ../shared
this changed the lib folder structure and lib/index.js has been moved to lib/functions/src/index.js
however the main entry point in the package.json was still pointing to the old lib/index.js which was still there.
To fix:
delete lib folder
change the main entry in the tsconfig.json accordingly to new lib structure
My best guess right now: my code as an error. When I simplify the code, deployment works.
Related
I am trying to run yarn run dev on my Next.js app but it always builds the .next directory and doesn't update the code for me to test.
It seems to be using the build folder even though I am trying to run a dev copy.
It's straight from create next app so not sure why it's doing this all of a sudden.
Even deleting .next file just recreates it on save.
I had to delete react and react-dom from package.json and then re-install them. Thanks
When I run the command:
PS C:\Users\PC\Desktop\Project> firebase init
it says:
You're about to initialize a Firebase project in this directory:
C:\Users\PC
I have tried running it in C:\Users and it worked properly, it won't go anywhere farther than C:\Users\PC
Can anyone help me with this?
When you run firebase init, then first thing is does is check parent directories for the presence of a hidden ".firebaserc" file to see if there is a project already created. If the file isn't found, it will create a new project in the current directory. If the file is found, it assumes you are working with an existing project in the stated folder.
You have a .firebaserc file in C:\Users\PC. If this is not what you expect, and you don't actually have a project there, d then you should probably just delete that file and start over.
So I have a cap file linked to my github and setup to deploy my project to my server. When I run
bundle exec cap prod deploy it all works without a hitch.
I can see my code being cloned from my repo, a new release folder is created and symlinked to the current folder. However any changes I've made to my code aren't reflected.
The repo being cloned is a fork of the original repo which I created when I began working on the project. I haven't made any changes to code base except adding a single line to a twig file.
I have updated the deploy.rb so that it pulls from my forked repo instead of the original one and can see the code change in my latest commit. However the change is not reflected on the site.
Any ideas why this might be happening?
Cheers
Two possibilities come to mind other than using the incorrect URL to the forked git repository -
I occasionally try to deploy a new copy of my own site, but I have not yet pushed the latest code from my development server (and the local repo) to the live repo on Github, but it is from Github that the code is being fetched from during deployment.
As a final step, Capistrano changes the location that the 'current' symlink points to the newly deployed directory in the 'releases' directory. Your webserver (apache or Nginx must be set to use the 'current' symlink) as part of the base directory (it will probably be ..../current/web/, and then auto-load app.php from that directory, unless there a subdirectory/file exists, for .CSS/JS/images/etc). If the webserver config refers to the 'release' directory, and not the symlink, it will only be a specific, older, deployment.
I'm new to node.js, sails.js and grunt.js.
When I run "sails lift" it does not create the .tmp folder and copy the assets to that folder.
However, when I run "grunt" in the project folder, the .tmp folder does get created and the assets do get copied over.
Anyone have suggestions on how to fix so "sails lift" works without calling "grunt"?
Check if the sails process has the right privileges and you're not running short of space.
Also, try manually deleting the .tmp folder and lifting again. Sometimes there can be issues with automatic file removal if any of the files are in use.
im trying to install PhantomJS in a MeteorApp.
I have done those step:
Add the npm package
meteor add meteorhacks:npm
Run meteor to let the npm package to pre-initialise
meteor
A file packages.json has been created at the root. Edit it to:
{
"phantomjs": "1.9.13"
}
A this point everything seem to work. But i try to test with this exemple that ive found here :
https://github.com/gadicc/meteor-phantomjs
But i dont understand where to put my phantomDriver.js
Why is phantomDriver.js is in assets/app/phantomDriver.js... but after, they say to create the file in ./private/phantomDriver.js...
Thank for clear explication :)
In development mode you create the file in /private/phantomDriver.js. When you build a meteor app it refactors everything into an application bundle which can be run.
After meteor builds your app it stores stuff from private into assets. For phantomjs to execute this file it needs to look in this directory. You don't have to create it. This is how meteor works internally.
If you look in your .meteor/local/build/programs/server directory the assets directory is there with anything you placed in private.
From the context of where your meteor code runs (the server directory above) the assets directory runs from this directory when your project is running.
Keep in mind when you deploy your app it loses its entire project structure and becomes something else. Gadi's phantomjs project is designed to work in production environments too.
TLDR; Don't worry about the assets directory, keep your file in /private/phantomDriver.js. Meteor should take care of the rest.