How to run GUI Applications like firefox in docker container ?
Since Docker is running default in bash mode we provide docker an image which is called dockerfile by which docker is able to run that image in GUI mode.
Steps to create custom dockerfile is as follows :-
Step 1 : Create a custom dockerfile by using the command
vim dockerfile
Step 2 : Create a docker script that will create a custom image.
FROM ubuntu:latest
RUN apt-get -y update
RUN apt-get -y install firefox
RUN apt-get -y install xauth
CMD firefox
Step 3 : Build a custom file using the following command
docker build sample/ -t firefox
Comments