-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docker Build - Create a default Docker file if there is not one #444
Comments
I think we can consider that as well, but if this start to get customizable more than two items, so better to let they create their own Dockerfile. |
I would say, the CMD and the FROM are the 2(or 3 if you include the version tag) things that a user should be able to customize if using the default dockerfile that nodeshift would create. |
One thing I noticed is that we need to add Dockerfile in files section of package.json
|
Probably there is a way to add the Dockerfile to the tar file without expect the user and/or nodeshift change package.json of the app. |
If the user choose the path were we are creating a Dockerfile for them, then we can just add it to the tar file when we create it and don't need to worry about adding anything to their package.json If they already have a Dockerfile and want to use that, then they need to make sure they add it to their files property |
It took me a while to understand what was going on with: I'm using the following
|
If someone is using the
--build.strategy=Docker
flag, nodeshift will expect that they have supplied a Dockerfile with their source code.It might be a nice feature to generate a very basic Dockerfile if they don't have one. We could base it off of this Dockerfile, which is how the Nodejs.org "dockerize a node app" article does it
We will need to determine what node image to default to. Most likely we could default to the s2i image we already default to, and the
--dockerImage
and--dockerTag
flags could be used to overwrite that value and use any node.js docker image/tagDo we also add the ability for someone to overwrite what the Dockerfile CMD does? I think the link i shared above uses server.js, but a user might want to change that. or at that point, do they create their own Dockerfile?
The text was updated successfully, but these errors were encountered: