![]() ![]() All dependencies should be installed from scratch. We don't want a node_modules folder in our docker container. # If you are building your code for production # A wildcard is used to ensure both package.json AND package-lock.json are copied Now let's copy a Dockerfile from official Nodejs website. The app should be availbale on Step 2 - Make a docker container Here is hello world nodejs app in a single file server.js // server.js Now you have package.json file with express as a dependency in it. First, you should initialize a new package npm init -yĪnd install express framework.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |