<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Sanchitha Udana Wijesundara</title>
    <description>The latest articles on DEV Community by Sanchitha Udana Wijesundara (@sanchithaudana).</description>
    <link>https://dev.to/sanchithaudana</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1371489%2F17f05ea4-33fe-476c-9816-9b174045b8c3.jpeg</url>
      <title>DEV Community: Sanchitha Udana Wijesundara</title>
      <link>https://dev.to/sanchithaudana</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/sanchithaudana"/>
    <language>en</language>
    <item>
      <title>How to Create Docker Image for HTTPD service, including portfolio web site.</title>
      <dc:creator>Sanchitha Udana Wijesundara</dc:creator>
      <pubDate>Fri, 22 Mar 2024 10:11:05 +0000</pubDate>
      <link>https://dev.to/sanchithaudana/how-to-create-docker-image-for-httpd-service-including-portfolio-web-site-2gb1</link>
      <guid>https://dev.to/sanchithaudana/how-to-create-docker-image-for-httpd-service-including-portfolio-web-site-2gb1</guid>
      <description>&lt;p&gt;&lt;strong&gt;01. Create a Dockerfile inside your portfolio web site project folder.&lt;/strong&gt;&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;that file name must be &lt;strong&gt;Dockerfile&lt;/strong&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;strong&gt;02. Use the Base image as HTTPD&lt;/strong&gt;&lt;br&gt;
create the "Dockerfile" like below.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9i8buymktamtiil61x5d.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9i8buymktamtiil61x5d.png" alt="Image description" width="800" height="506"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;03. After create Dockerfile you can run below command to build the docker image&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;docker build -t imageName .
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;04. After create docker image you can use to create docker container using below command.&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;docker run -d --name containerName -p 8080:80 imageName
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;You can access the website using &lt;a href="http://localhost:8080"&gt;http://localhost:8080&lt;/a&gt;&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>docker</category>
      <category>dockerfile</category>
      <category>dockerimage</category>
      <category>dockerhub</category>
    </item>
  </channel>
</rss>
