Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

Commit

Permalink
Merge pull request #830 from davidnuzik/misc-fixes
Browse files Browse the repository at this point in the history
[Docs] Many small tweaks
  • Loading branch information
davidnuzik authored Nov 18, 2019
2 parents 7765776 + 43b31f6 commit f99a89d
Show file tree
Hide file tree
Showing 16 changed files with 104 additions and 104 deletions.
8 changes: 4 additions & 4 deletions docs/autoscaling.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Autoscaling

Rio deploys a simple autoscaler to watch metrics from workloads and scale application based on current in-flight requests.
Rio deploys a simple autoscaler to watch metrics from workloads and scale applications based on current in-flight requests.

Note: Metric is scraped from linkerd-proxy sidecar, this requires your application to be injected with linkerd sidecar.
Note: Metrics are scraped from the linkerd-proxy sidecar, this requires your application to be injected with the linkerd sidecar.
This will happen by default when running new workloads.

To enable autoscaling:
Expand All @@ -17,7 +17,7 @@ $ rio run --scale 1-10 --concurrency 20 -p 8080 strongmonkey1992/autoscale:v0
$ rio run --scale 0-10 -p 8080 strongmonkey1992/autoscale:v0
```

To put load the following example use [hey](https://github.com/rakyll/hey):
To test putting load on the service, use [hey](https://github.com/rakyll/hey):

```bash
hey -z 3m -c 60 http://xxx-xx.xxxxxx.on-rio-io
Expand All @@ -29,4 +29,4 @@ $ watch rio ps
Note: `concurrency` means the maximum in-flight requests each pod can take. If your total in-flight request is 60 and concurrency
is 10, Rio will scale workloads to 6 replicas.

Note: When scaling application to zero, the first request will take longer.
Note: When scaling an application to zero, the first request will take longer.
14 changes: 7 additions & 7 deletions docs/cli-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ rio export --riofile namespace/default

## image

List images built from local registry
List images built from the local registry

##### Usage
```
Expand Down Expand Up @@ -293,7 +293,7 @@ rio inspect taskrun/affectionate-mirzakhani-mfp5q-ee709-4e40c

## install

Install rio management plane
Install the Rio management plane

See the [install docs](install.md) for more info.

Expand All @@ -315,12 +315,12 @@ rio install [OPTIONS]

**--check**

Check if rio is installed in the current cluster without deploying rio controller.
If rio has not been installed, this command might hang on `Waiting for rio controller to initialize`.
Check if Rio is installed in the current cluster without deploying the Rio controller.
If Rio has not been installed, this command might hang on `Waiting for rio controller to initialize`.

**--disable-features**

Choose features to be disabled when starting rio control plane. Below are a list of available features
Choose features to be disabled when starting the Rio control plane. Below are a list of available features

| Feature | Description |
|-------------|---------------------------------------------------|
Expand All @@ -335,7 +335,7 @@ Choose features to be disabled when starting rio control plane. Below are a list
**--ip-address**

Manually specify IPAddress for API gateway services. The IP will be used to generate a record for the cluster domain.
By default, if this flag is not specified, rio will use the IP of [Service Loadbalancer](https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/) that points to API gateway.
By default, if this flag is not specified, Rio will use the IP of [Service Loadbalancer](https://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/) that points to API gateway.

Note: If service loadbalancer cannot be provisioned, [Nodeport](https://kubernetes.io/docs/concepts/services-networking/service/#nodeport) is used to expose API gateway.

Expand Down Expand Up @@ -667,7 +667,7 @@ rio stage --edit demo v2

## systemlogs

Print the logs from Rio management plane
Print the logs from the Rio management plane

##### Usage
```
Expand Down
8 changes: 4 additions & 4 deletions docs/concept.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,16 @@ on hostname, path, HTTP headers, protocol, and source.
### External Service

External Service provides a way to register external IPs or hostnames in the service mesh so they can be accessed by Rio services.
Also, rio services running in one namespace can be declared as ExternalServices in another namespace.
Also, Rio services running in one namespace can be declared as ExternalServices in another namespace.

### Public Domain

Public Domain can be configured to assign a service or router a vanity domain like www.myproductionsite.com.

### Cluster Domain

Cluster Domain is a dns name that can be configured globally on each service so that each service will have an endpoint like $service_name-$namespace.xxx.clusterdomain.
By default Rio will create and assign the `on-rio.io` dns name to each service, so it will have a dns name like `$name-$namespace.xxx.on-rio.io`.
Cluster Domain is a DNS name that can be configured globally on each service so that each service will have an endpoint like $service_name-$namespace.xxx.clusterdomain.
By default Rio will create and assign the `on-rio.io` DNS name to each service, so it will have a DNS name like `$name-$namespace.xxx.on-rio.io`.

### Configs

Expand All @@ -41,4 +41,4 @@ They are pieces of configuration that can be mounted into pods so that configura

### Secrets

Secrets are a standard Kubernetes resource and can be referenced by rio services. They contain sensitive data that can be mounted into pods.
Secrets are a standard Kubernetes resource and can be referenced by Rio services. They contain sensitive data that can be mounted into pods.
26 changes: 13 additions & 13 deletions docs/continuous-deployment.md
Original file line number Diff line number Diff line change
@@ -1,41 +1,41 @@
# Continuous Deployment

Rio enables continuous deployment with Github by default.
Rio enables continuous deployment with GitHub by default.
This allows developers to streamline their focus on their git repository and worry less about their deploys.

The most versatile use case is in [this example](#pull-request-builds).


### Basic Example
Deploy a workload with rio from a public Github repository that you have push access to:
Deploy a workload with Rio from a public GitHub repository that you have push access to:
`rio run -n cd-demo -p 8080 https://github.com/rancher/rio-demo`

Make a commit to the master branch of the repo.
You should notice that within 15 seconds, rio rebuilds your workload (`rio build history`) and updates it to match the committed changes.
You should notice that within 15 seconds, Rio rebuilds your workload (`rio build history`) and updates it to match the committed changes.


### Advanced Usage
#### Pull Request Builds
This feature uses a webhook to create a deployment when submitting a Pull Request to your tracked branch (master by default).
A new workload version will be staged in rio, associated to the same app that was initially created.
You can view the endpoint results directly from the PR by clicking "View deployment" in Github.
If the pull request is merged, it will then update the app endpoint in rio to point to this new version.
A new workload version will be staged in Rio, associated to the same app that was initially created.
You can view the endpoint results directly from the PR by clicking "View deployment" in GitHub.
If the pull request is merged, it will then update the app endpoint in Rio to point to this new version.

It only takes 2 steps:

1. [Configure Webhook](./webhooks.md) for your repository. For this example, you only need to set the webhook up.
2. `rio run -p 8080 -n example-cd --build-webhook-secret=githubtoken --build-pr --template https://github.com/example/example-repo`

NOTE: if your repository is private, you will also need to [create credentials secret](#private-github-repo) and use the correct additional flags when running your workload.
NOTE: if your repository is private, you will also need to [create a credentials secret](#private-github-repo) and use the correct additional flags when running your workload.


#### Automatic Versioning
Notice the `--template` flag specified in the [Pull Request Builds](#pull-request-builds) scenario.
With this flag set, rio will automatically configure versions for this workload when new commits are pushed to the Github repo.
With this flag set, Rio will automatically configure versions for this workload when new commits are pushed to the GitHub repo.
As soon as the workload is ready, it will promote that version to have 100% of the app endpoint weight.
The only case where it won't automatically promote is when using the `--build-pr` flag as well and the build is from the PR branch.

If the `--template` flag is not set, then every subsequent build will overwrite the current version, including builds from PR branch with `--build-pr` flag set.
If the `--template` flag is not set, then every subsequent build will overwrite the current version, including builds from the PR branch with `--build-pr` flag set.


#### Private Github Repo
Expand All @@ -49,7 +49,7 @@ You can do this with Git Basic Auth or SSH Auth:
username[]: $(your GH username)
password[******]: $(your GH password)
```
2. Create workload pointing to your repo using standard git checkout. For example:
2. Create a workload pointing to your repo using standard git checkout. For example:
`rio run -p 8080 https://github.com/example/example-private-repo`
- SSH Auth:
1. Configure git sshkey auth credential secrets. This should use a key that does not have a password associated to it:
Expand All @@ -64,20 +64,20 @@ You can do this with Git Basic Auth or SSH Auth:


#### Private Docker Registry
1. Configure docker credential secret.
1. Configure the Docker credential secret.
```bash
$ rio secret create --docker
Select namespace[default]: $(put the same namespace with your workload)
Registry URL[https://index.docker.io/v1/]: $(found with "docker info | grep Registry")
username[]: $(your docker username)
password[******]: $(your docker password)
```
2. Create workload pointing to your image. For example:
2. Create a workload pointing to your image. For example:
`rio run --image-pull-secrets dockerconfig -p 8080 imageorg/imagename:version`


### Useful Options
There are many options available for use when running workloads in rio. These are just a few that are useful for CD:
There are many options available for use when running workloads in Rio. These are just a few that are useful for CD:

| Option | Type | Description |
|------|----| -------------|
Expand Down
4 changes: 2 additions & 2 deletions docs/dashboard.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Dashboard

Rio ships with a built-in dashboard. To enable dashboard:
Rio ships with a built-in dashboard. To enable the dashboard:

```bash
$ rio dashboard
```

Then follow the instructions prompted in UI.
If a browser does not automatically open, the output of the command should have a URL that you can use to access the dashboard.
If a browser does not automatically open, the output of the command should have a URL that you can use to access the dashboard.
8 changes: 4 additions & 4 deletions docs/developing-application-using-rio.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Developing application using Rio

Rio CLI provides an easy way to build and deploy your applications into a k8s cluster. It takes advantage of [Riofile](./riofile.md) and [buildkit](https://github.com/moby/buildkit) to
The Rio CLI provides an easy way to build and deploy your applications into a Kubernetes cluster. It takes advantage of [Riofile](./riofile.md) and [buildkit](https://github.com/moby/buildkit) to
build images and update deployments with them.

#### Using Riofile to develop applications
Expand Down Expand Up @@ -34,7 +34,7 @@ services:
$ rio up
```

5. Check with `rio ps`. It should create a service with URL serving the content. It should be serving Blue cows.
5. Check with `rio ps`. It should create a service with URL serving the content. It should be serving blue cows.

6. Open the `Dockerfile` and change `ENV COW_COLOR` from `blue` to `red`.

Expand All @@ -46,15 +46,15 @@ By following the example above, you can now develop your code locally and run `r

#### Manually build and run

You can also use Rio CLI to build and run image locally in your cluster.
You can also use the Rio CLI to build and run an image locally in your cluster.

1. Go to the root directory of repo and run

```bash
$ rio build
```

2. Wait for image to be built. Once it is done, run
2. Wait for the image to be built. Once it is done, run

```bash
$ rio images
Expand Down
12 changes: 6 additions & 6 deletions docs/faq.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
# FAQs

Frequently asked questions about working with rio
Frequently asked questions for Rio
##

**Q:** What Kubernetes version do I need to run rio?

**A:** We recommend using [k3s](https://k3s.io/)!
Rio should work with any kubernetes version v1.15+. If using a managed kubernetes instance, use the latest version available.
We have internally tested major features of rio with GKE v1.14.8-gke.12 and EKS v1.14.8-eks-b7174d.
**A:** We recommend using [K3s](https://k3s.io/)!
Rio should work with any Kubernetes version v1.15+. If using a managed Kubernetes instance, use the latest version available.
We have internally tested major features of Rio with GKE v1.14.8-gke.12 and EKS v1.14.8-eks-b7174d.
##

**Q:** Why doesn't the first workload I create have a version but staged workloads do?

**A:** The first workload you create is always `v0` by default, and this is hidden in the CLI to avoid clutter.
##

**Q:** Why is the Rio cli stuck when I run a command?
**Q:** Why is the Rio CLI stuck when I run a command?

**A:** Verify you have used an available option and don't have any typos.
If you are sure there are no typos in your command, feel free to submit an issue with the exact command and options you used.
Expand All @@ -29,7 +29,7 @@ If you are sure there are no typos in your command, feel free to submit an issue
**Q:** Why can't I remove services that were created with a Riofile?

**A:** If you wish to delete ALL resources associated to the stack, delete the stack itself:
1. Obtain stack name: `rio stacks`
1. Obtain the stack name: `rio stacks`
2. Delete it: `rio rm <stack name>`

If instead you wish to remove a specific resource, then remove it from the Riofile and reapply it: `rio up`
Expand Down
22 changes: 11 additions & 11 deletions docs/install.md
Original file line number Diff line number Diff line change
@@ -1,54 +1,54 @@
# Install Rio

Rio can be installed from both CLI or kubernetes manifest.
Rio can be installed from both the CLI or a Kubernetes manifest.

1. Download the latest release.

```bash
$ curl -sfL https://get.rio.io | sh -
```

Note: by default it will only download the latest release from github. To test a pre-release or alpha build, run.
Note: by default the script will only download the latest release from GitHub. To test a pre-release or alpha build, run.

```bash
$ curl -sfL https://get.rio.io | INSTALL_RIO_VERSION=${version} sh -
```

2. Prepare a Kubernetes cluster, see [Clusters and Providers](#clusters-and-providers). Setup KUBECONFIG environment variable to point to your kubernetes cluster.
2. Prepare a Kubernetes cluster, see [Clusters and Providers](#clusters-and-providers). Set the KUBECONFIG environment variable to point to your Kubernetes cluster.

3. Run

```bash
$ rio install
```

Note: to install rio from kubernetes manifest, run `rio install --yaml`. It will print out kubernetes manifest instead of
installing rio directly, so that you can apply the manifest later.
Note: to install Rio a Kubernetes manifest, run `rio install --yaml`. It will print out the Kubernetes manifest instead of
installing Rio directly, so that you can apply the manifest later.

## Options

See the [CLI install reference docs](cli-reference.md#install) for complete list of options.

## Clusters and Providers

A 1.15 or higher version of kubernetes is recommended.
A 1.15 or higher version of Kubernetes is recommended.

See the kubernetes [getting started guide](https://kubernetes.io/docs/setup/) to help choose a cluster type.
See the Kubernetes [getting started guide](https://kubernetes.io/docs/setup/) to help choose a cluster type.

**Internal vs external IP address**

Some cloud providers will use an internal IP address by default and Rio will use that for its cluster domain.
You can override this during cluster setup by configuring external IP's, or by using a cloud-provider to setup a load balancer which will have an external IP.

For an example of installing a cluster with a cloud provider on Linode using Rancher, see [bullet #8 on this doc](https://www.linode.com/docs/kubernetes/how-to-deploy-kubernetes-on-linode-with-rancher-2-x/#provision-a-cluster).
For an example of installing a cluster with a cloud provider on Linode using Rancher, see [step #8 on this doc](https://www.linode.com/docs/kubernetes/how-to-deploy-kubernetes-on-linode-with-rancher-2-x/#provision-a-cluster).

**k3s**
**K3s**

When installing on k3s use the `--no-deploy traefik` flag.
When installing on K3s use the `--no-deploy traefik` flag.

**EKS**

Ensure you are running enough nodes with proper instance types to allow for the rio and kubernetes systems to run at least 45 pods.
Ensure you are running enough nodes with proper instance types to allow for the Rio and Kubernetes systems to run at least 45 pods.
See the docs to help determine proper sizes:

* Guide: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#AvailableIpPerENI
Expand Down
6 changes: 3 additions & 3 deletions docs/monitoring.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
# Monitoring

Rio deploys [linkerd](https://linkerd.io/) to collect metrics from workloads. You can use Rio dashboard or linkerd dashboard to monitor traffic for your applications.
Rio deploys [linkerd](https://linkerd.io/) to collect metrics from workloads. You can use the Rio dashboard or linkerd dashboard to monitor traffic for your applications.

To run Rio dashboard, check [here](./dashboard.md).

To run linkerd dashboard:
To run the linkerd dashboard:

```bash
$ rio linkerd

# if you have linkerd binary
$ linkerd dashboard
```
```
Loading

0 comments on commit f99a89d

Please sign in to comment.