Skip to content

Commit

Permalink
documentation for running event-gateway on k8s (#498)
Browse files Browse the repository at this point in the history
* adding more changes to README

* interim commit for more README updates

* more updates to README

* adding in fedora section

* moving README one level higher

* adding in ports description

* breaking up lines a bit

* fixing the event url

* adding in dev flag for running

* adding example function register

* updating data

* updating for typo

* cleaning up k8s content

* updating based on feedback

* interim commit for k8s

* cleaning up helm files

* moving to template variables

* initial commit minikube readme

* updating README

* updating number

* updating formatting

* more formatting

* updating based upon feedback

* updating with trigger

* updating the TOC

* updating based upon further feedback

* updating with more feedback

* updating to query all event types

* updating the README for the contrib level folder

* updating to builleted items

* removing extraneous reference

* updating README with feedback

* cleaning up doublenote
  • Loading branch information
sebito91 authored Aug 16, 2018
1 parent 8b31577 commit 02e8f5f
Show file tree
Hide file tree
Showing 10 changed files with 451 additions and 2,634 deletions.
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ If you don't want to run the Event Gateway yourself, you can use the hosted vers
There is a [official Docker image](https://hub.docker.com/r/serverless/event-gateway/).

```bash
docker run -p 4000:4000 -p 4001:4001 serverless/event-gateway -dev
docker run -p 4000:4000 -p 4001:4001 serverless/event-gateway --dev
```

### Binary
Expand All @@ -89,9 +89,14 @@ On Windows download [binary](https://github.com/serverless/event-gateway/release
Then run the binary in development mode with:

```bash
$ event-gateway -dev
$ event-gateway --dev
```

### Kubernetes

The repo contains `helm` [charts](contrib/helm/README.md) for a quick deploy to an existing cluster using native nginx Ingress. To deploy
a development cluster you can follow the [minikube](contrib/helm/MINIKUBE.md) instructions.

---

If you want more detailed information on running and developing with the Event Gateway,
Expand Down
6 changes: 6 additions & 0 deletions contrib/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Event Gateway Contributions

This folder contains services and contributions which complement the Event Gateway.

+ Install Event Gateway on Kubernetes using [helm](helm/README.md)
+ Provision the Event Gateway on AWS ECS Fargate using [terraform](terraform/README.md)
66 changes: 66 additions & 0 deletions contrib/helm/MINIKUBE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# Install Minikube for Local Development

To develop and deploy the `event-gateway` and all related elements locally, the easiest method includes using
the [minikube](https://github.com/kubernetes/minikube) toolset. To get started, set up your local cluster with the
following instructions...

## Contents
1. [Fedora/RHEL/CentOS](#fedora-rhel-centos)
1. [Debian/Ubuntu](#debian-ubuntu)
1. [MacOS](#macos)

### Fedora/RHEL/CentOS
+ Install the prerequisite packages:
```bash
sudo dnf install kubernetes libvirt-daemon-kvm qemu-kvm nodejs docker
```

+ Ensure your user is added to the `libvirt` group for VM access. You can verify with `getent group libvirt` once done.
```bash
sudo usermod -a -G libvirt $(whoami)
```

+ Next, add the `libvirt` group to your current user grouplist. Verify by running `id` once done.
```bash
newgrp libvirt
```

+ Add the [docker-machine](https://github.com/docker/machine) binary to your system
```bash
curl -L https://github.com/docker/machine/releases/download/v0.15.0/docker-machine-$(uname -s)-$(uname -m) >/tmp/docker-machine && \
chmod +x /tmp/docker-machine && \
sudo cp /tmp/docker-machine /usr/local/bin/docker-machine
```

+ Add the CentOS `docker-machine` kvm driver. It's ok if you're not using CentOS as the driver should **still work**™
```bash
sudo curl -L https://github.com/dhiltgen/docker-machine-kvm/releases/download/v0.10.0/docker-machine-driver-kvm-centos7 > /tmp/docker-machine-driver-kvm && \
sudo chmod +x /tmp/docker-machine-driver-kvm && \
sudo mv /tmp/docker-machine-driver-kvm /usr/local/bin/docker-machine-driver-kvm
```

+ Download the minikube instance for your system
```bash
curl -Lo minikube https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 && \
sudo chmod +x minikube && \
sudo mv minikube /usr/local/bin/
```

+ Finally, start up your minikube service! **NOTE:** the instructions recommend using `kvm2` but please use the version that matches your system install
```bash
minikube start --vm-driver kvm2
```

+ Once everything is running you should be able to view your running cluster status
```bash
minikube status
minikube service kubernetes-dashboard --namespace kube-system
```

### Debian/Ubuntu

PENDING

### MacOS

PENDING
Loading

0 comments on commit 02e8f5f

Please sign in to comment.