'Can I make a Docker image with the current computer's settings as it is?

I have built Apache2 web server in Offline environment on Debian environment. Can I make this setting as a Docker Image? If yes, please tell me how.



Solution 1:[1]

Assuming you have docker installed on your Debian host. Basic skeleton will be like this.
You would create a Dockerfile with the following content.

# Filename: Dockerfile 
FROM httpd:2.4
COPY ./public-html/ /usr/local/apache2/htdocs/
COPY ./my-httpd.conf /usr/local/apache2/conf/httpd.conf

and then run

$ docker build -t my-apache2 .

You can also expose port 80 or 8080 in the Dockerfile and have it start httpd server by default.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Pankaj Saini