Docker GUI Task26
This article describe how we can launch GUI software on Docker.
Task Description
*GUI container* on the *Docker*
Lets begin...?
Step 1:- Create a dockerGui folder and in this folder create a file name as Dockerfile.
Step 2:- Below is the Dockerfile code to create a docker image which should have firefox installed.
FROM centos
RUN yum install firefox -y
CMD ["usr/bin/firefox"]
Step 3:- Now?build?this Dockerfile to create a image using docker build command.
Now?image successfully created.?Just for cross verify can use below command.
Step 4:- Running Firefox container in GUI mode
docker container run --help
docker run -it --net=host --env="DISPLAY" firefox:<tag>
So finally if you run above command. Application?( Firefox?) will launch inside docker container.
It will automatically start the firefox.
Thank