How to use a Fedora Docker image to build a code? [closed]
Hello,
I want to build a C++ code with cmake that needs gcc6. From the discussion in https://ask.fedoraproject.org/en/ques..., @hedayat recommend to use a docker image to install gcc6. I think that is a good idea to avoid a system conflict later.
Now, found a fedora gcc6 docker image and I executed docker pull mccaskey/base-fedora-gcc6
, then docker run mccaskey/base-fedora-gcc6
. Now, docker ps
shows me that the container is running.
But then how can I build the C++code with cmake? I cannot find a gcc6 binary on my terminal.
Shall I write the cmake build procedure also in the Dockerfile?
if yes, where can I find the Dockerfile of the downloaded image in the filesystem?
Thanks.
Ok, I found out how to build a docker image with gcc6 using a customized Dockerfile. I don't need that base-fedora-gcc6 image anymore.