Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in DevOps and Agile by (29.3k points)

I'm facing an issue with the docker file. The image was created and by that, image container is also created but apache is not automatically getting started or there is some issue. Because when I go to the browser and use the port I have mentioned, it does not work. 

Please help me with the above issue.

1 Answer

0 votes
by (50.2k points)

You need to start the apache service inside your container manually. If you need to do it automatically using dockerfile then use:

RUN systemctl start apache2

CMD apachectl -D FOREGROUND

This above commands will help you to enable the apache using a dockerfile. 

For more information, check out this Docker Tutorial.

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Mar 31, 2020 in DevOps and Agile by chandra (29.3k points)

Browse Categories

...