[scl.org] rhscl dockerfiles

Honza Horak hhorak at redhat.com
Thu Aug 6 15:08:13 UTC 2015


Adding Tomas into CC, he maintains nodejs and has better knowledge what 
it means to run nodejs app.

My nodejs-unexperienced thought would be you can create a new docker 
image, that will use `FROM: nodejs-010-rhel7` and:
* add the app code somewhere into the image (e.g. into /opt/app-root/app)
* changing CMD to run your application on pure `docker run`

Or, theoretically, you don't have to create a new layer (image), just 
use volume mounting to get your app into the container. It would mean to 
run the image this way:

#> docker run -v /your/app:/opt/app-root/app nodej-010-rhel7 
/opt/app-root/app/run.sh

But I may be also wrong about how it is the best to do it. Or whether 
this way is something we should or shouldn't recommend.

Sharing also to the ML, maybe others might have different opinions/ideas 
or at least issues.

Honza

On 08/06/2015 03:42 PM, David Martin wrote:
> If there's a recommended way to use the sti nodejs image for simply
> running a node app, that'd be great.
> I'll spend some time trying to figure it out as I can't find Usage docs
> other than doing an sti build.
>
> re: Dockerfile.rhel7,
> Ah, I didn't spot this at first. Thanks
>
> On Thu, Aug 6, 2015 at 2:18 PM, Honza Horak <hhorak at redhat.com
> <mailto:hhorak at redhat.com>> wrote:
>
>     Well, you can, but at least to my understanding you shouldn't need
>     it. Even if the sti scripts are part of the image, you don't have to
>     use them if you don't want to. Or do you have a use case where you
>     cannot use an image with sti scripts?
>
>     btw. if you seek for rhel dockerfile, just look at Dockerfile.rhel7
>     in the same directory.
>
>     Honza
>
>     On 08/06/2015 02:05 PM, David Martin wrote:
>
>         Ok, thanks.
>
>         I don't understand why though. Its an STI image, and its centos.
>
>         I guess I can take the original rhel7 nodejs dockerfile and build it
>         myself to get a non STI image on rhel7.
>
>         On Thu, Aug 6, 2015 at 12:45 PM, Honza Horak <hhorak at redhat.com
>         <mailto:hhorak at redhat.com>
>         <mailto:hhorak at redhat.com <mailto:hhorak at redhat.com>>> wrote:
>
>              On 08/06/2015 01:35 PM, David Martin wrote:
>
>                  Hi Honza,
>
>                  I'm looking to use the rhel7.nodejs010 dockerfile from
>         the rhscl
>                  repo
>         https://github.com/sclorg/rhscl-dockerfiles
>                  however, I see that it was recently removed.
>                  In the removal comment you mentioned "Remove
>         dockerfiles sources
>                  that
>                  have upstream under https://github.com/openshift/"
>                  Maybe I'm misunderstanding something or missing a part
>         of the
>                  picture,
>                  but where is the upstream you are referring to?
>                  Is it the STI image based on centos you are referring
>         to here?
>         https://github.com/openshift/sti-nodejs/blob/master/0.10/Dockerfile
>
>
>              Yes, that one it is. After discussion we decided not to
>         continue
>              with the original rhel7.nodejs010 dockerfile and only use
>         https://github.com/openshift/sti-nodejs/blob/master/0.10/Dockerfile
>              in RH -- that one is base for official RH image now.
>
>              Honza
>
>                  Thanks
>
>                  David Martin
>
>
>




More information about the SCLorg mailing list