Solution: Run an Apache Container
Explore how to run an Apache container within Kubernetes by creating a pod manifest file, applying it, and using port-forwarding to expose the service. Learn to access and update the container's web content by executing commands inside the pod.
We'll cover the following...
We'll cover the following...
Running an Apache container
Creating a pod manifest file to run an Apache file is not much different than what we have seen before.
apiVersion: v1
kind: Pod
metadata:
name: apache
spec:
containers:
- name: apache-container
image: httpdTesting the Solution
Note: Please run the above widget, and wait for the application to load before clicking on the above URL.
In the apache.yaml file, we’re creating a pod named apache. We can name it whatever we want. But for this solution, we’re naming it “apache.” We can change the name of ...