diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 000000000..f8601654e --- /dev/null +++ b/Dockerfile @@ -0,0 +1,6 @@ +FROM ubuntu +RUN apt update +RUN apt install apache2 -y +ADD . /var/www/html/ +ENTRYPOINT apachectl -D FOREGROUND + diff --git a/deploy.yaml b/deploy.yaml new file mode 100644 index 000000000..712b41eb9 --- /dev/null +++ b/deploy.yaml @@ -0,0 +1,21 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: mydeployment + labels: + app: apache2 +spec: + replicas: 5 + selector: + matchLabels: + app: apache2 + template: + metadata: + labels: + app: apache2 + spec: + containers: + - name: mydeplymentcont + image: reemar123/test:latest + ports: + - containerPort: 80 diff --git a/index.html b/index.html index 19c25caa0..c89f076ec 100644 --- a/index.html +++ b/index.html @@ -1,6 +1,6 @@ - Intellipaat + Reema R

Hello world!

diff --git a/service.yaml b/service.yaml new file mode 100644 index 000000000..29767fe9f --- /dev/null +++ b/service.yaml @@ -0,0 +1,12 @@ +apiVersion: v1 +kind: Service +metadata: + name: myservice +spec: + type: NodePort + selector: + app: apache2 + ports: + - port: 80 + targetPort: 80 + nodePort: 30085