RUN GUI Applications In Docker Container
RUN GUI Applications In Docker Container
What is Docker?
- Docker is a containerization platform tool for building an application in which container contains packaged binary files and its library files with its required dependencies, and further these containers are easily shipped to run on other machines.
- Each and every application runs on separate containers and has its own set of dependencies & libraries.
What is a Docker container?
- Docker containers are basically runtime instances of Docker images.
- Docker is a tool designed to make it easier to create, deploy and run applications by using containers.
Now, let’s see how to launch GUI application in Docker -
1. Make & Go to Directory
mkdir dockergui
cd dockergui
2 . Create A Dockerfile & Write Commands .
To create Dockerfile
vim dockerfile
What is Dockerfile?
A Dockerfile is a text document that contains all the commands a user could call on the command line to assemble an image.
3. Build the Docker image using Dockerfile.
docker build -t firefoxgui .
4.Launch the GUI Container.
docker run -it --name guifirefox --env="DISPLAY" --net=host firefoxgui:latest
--env="DISPLAY"
It is used to display the firefox on the docker
--net=host
It is used to set up the host adapter with the container
Launch Successful :)
Comments
Post a Comment