Skip to content

Commit

Permalink
prow/doc: updated the getting started guide about namespaces
Browse files Browse the repository at this point in the history
  • Loading branch information
idealhack committed Apr 26, 2019
1 parent faf86a5 commit d5f851f
Showing 1 changed file with 19 additions and 20 deletions.
39 changes: 19 additions & 20 deletions prow/getting_started_deploy.md
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,25 @@ label. When you make a change to the plugin config and push it with `make
update-plugins`, you do not need to redeploy any of your cluster components.
They will pick up the change within a few minutes.

### Set namespaces for prowjobs and test pods

Add the following to `config.yaml`:

```yaml
prowjob_namespace: default
pod_namespace: test-pods
```

By doing so, we keep prowjobs in the `default` namespace and test pods in the
`test_pods` namespace.

You can also choose other names. Remember to update the RBAC roles and
rolebindings afterwards.

**Note**: If you set or update the `prowjob_namespace` or `pod_namespace`
fields after deploying the prow components, you will need to redeploy them
so that they pick up the change.

### Add more jobs by modifying `config.yaml`

Add the following to `config.yaml`:
Expand Down Expand Up @@ -328,26 +347,6 @@ When you push or merge a new change to the git repo, the postsubmit job will run

For more information on the job environment, see [`jobs.md`](/prow/jobs.md)

### Run test pods in a different namespace

You may choose to keep prowjobs or run tests in a different namespace. First
create the namespace by `kubectl create -f`ing this:

```yaml
apiVersion: v1
kind: Namespace
metadata:
name: prow
```

Now, in `config.yaml`, set `prowjob_namespace` or `pod_namespace` to the
name from the YAML file. You can then use RBAC roles to limit what test pods
can do.

**Note**: If you set or update the `prowjob_namespace` or `pod_namespace`
fields after deploying the prow components, you will need to redeploy them
so that they pick up the change.

### Run test pods in different clusters

You may choose to run test pods in a separate cluster entirely. This is a good practice to keep testing isolated from Prow's service components and secrets. It can also be used to furcate job execution to different clusters.
Expand Down

0 comments on commit d5f851f

Please sign in to comment.