Setting Up Docker Terminal On WebApp….

Creating a Web Application for Docker (one of the great Containerization Tool which provides the user Platform as a Service (PaaS)) with creativity and UI/UX designing skills to make the web portal user friendly.

Sourabh Mishra
2 min readJun 26, 2021
The output of the webApp look like this.

Follow the steps to create this kind of WebApp.

I have put all of my code in my GitHub repository

link — https://github.com/code-sourabh/Linux-Terminal-WebApp.git

The code for HTML file is already there in repo with name index.html and is self explanatory.

To connect WebApp with docker we will use CGI programming.

The code for CGI python program is also present in GitHub repo.

Make a Note of few points-

- Make sure the httpd webserver we are using for CGI has it’s port open and is not restricted by firewall

- The docker never connect to external program by default due to it’s socket program functionality.

- To connect to docker with external program. make sure u allow other users to use docker.sock file. for this run the command.

# chmod 777 /etc/run/docker.sock

Make sure you copy the CGI file in /var/www/cgi-bin/ file.

Now start the Httpd services.

# systemctl start httpd

Now launch the WebApp and it will look like this..

Now run any docker command in the input box.

And VOILA……

--

--