Git Product home page Git Product logo

ingress-example's Introduction

Ingress Example

Install

The installation will slightly depend on the type of cluster that you are using.

For this tutorial, we are going to be using the docker-desktop cluster

We need two main components

  1. Ingress Controller
  2. Ingress resources

Let's set everything up.

We are going to be using the NGINX Ingress Controller. With the NGINX Ingress Controller for Kubernetes, you get basic load balancing, SSL/TLS termination, support for URI rewrites, and upstream SSL/TLS encryption

First off, let's clone this repository

git clone <repository>
cd ingress-example
cd app-one

now build your Docker image

docker build -t anaisurlichs/flask-one:1.0 .

You can test it out through

docker run -p 8080:8080 anaisurlichs/flask-one:1.0

And then we are going to push the image to our Docker Hub

docker push anaisurlichs/flask-one:1.0

We are going to do the same in our second example application

cd ..
cd app-two

build the docker image

docker build -t anaisurlichs/flask-two:1.0 .

push it to your Docker Hub

docker push anaisurlichs/flask-two:1.0

Now apply the deployment-one.yaml and the deployment-tow.yaml

kubectl apply -f deployment-one.yaml
kubectl apply -f deployment-two.yaml

Make sure they are running correctly

kubectl get all

Installing Ingress Controller

kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/controller-v0.44.0/deploy/static/provider/cloud/deploy.yaml

Installing Ingress Resource

kubectl apply -f ingress.yaml

make sure that everything is running correctly

kubectl get all -n ingress-nginx

Making paths happen kubernetes/ingress-nginx#3762

ingress-example's People

Contributors

anais-codefresh avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.