forked from draveness/istio
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Enable cluster wide installation in tests (istio#902)
* Enable cluster wide installation in tests * Check errors * Address code review comments * Code review * goftm -s * Fix the initializer * Updated readme * Try without initializer Former-commit-id: d24eca1
- Loading branch information
1 parent
5a20376
commit a68459e
Showing
9 changed files
with
120 additions
and
325 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,7 +33,7 @@ ZONE=us-central1-f | |
CLUSTER_VERSION=1.7.5 | ||
MACHINE_TYPE=n1-standard-4 | ||
NUM_NODES=1 | ||
CLUSTER_NAME=rbac-n-auth-$(uuidgen | cut -c1-8) | ||
CLUSTER_NAME=cluster-wide-auth-$(uuidgen | cut -c1-8 | tr "[A-Z]" "[a-z]") | ||
|
||
CLUSTER_CREATED=false | ||
|
||
|
@@ -56,6 +56,5 @@ CLUSTER_CREATED=true | |
|
||
kubectl create clusterrolebinding prow-cluster-admin-binding --clusterrole=cluster-admin [email protected] | ||
|
||
echo 'Running e2e rbac, no auth Tests' | ||
./prow/e2e-suite-rbac-no_auth.sh "${@}" | ||
|
||
echo 'Running cluster-wide e2e rbac, auth Tests' | ||
./prow/e2e-suite-rbac-auth.sh --cluster_wide "${@}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,7 +15,7 @@ gcloud container clusters create ${CLUSTER_NAME} --zone ${ZONE} --project ${PROJ | |
|
||
If you hit the error | ||
```bash | ||
Error from server (Forbidden): error when creating "install/kubernetes/istio-rbac-beta.yaml": clusterroles.rbac.authorization.k8s.io "istio-pilot" is forbidden: attempt to grant extra privileges: [{[*] [istio.io] [istioconfigs] [] []} {[*] [istio.io] [istioconfigs.istio.io] [] []} {[*] [extensions] [thirdpartyresources] [] []} {[*] [extensions] [thirdpartyresources.extensions] [] []} {[*] [extensions] [ingresses] [] []} {[*] [] [configmaps] [] []} {[*] [] [endpoints] [] []} {[*] [] [pods] [] []} {[*] [] [services] [] []}] user=&{[email protected] [...] | ||
Error from server (Forbidden): error when creating "install/kubernetes/istio.yaml": clusterroles.rbac.authorization.k8s.io "istio-pilot" is forbidden: attempt to grant extra privileges: [{[*] [istio.io] [istioconfigs] [] []} {[*] [istio.io] [istioconfigs.istio.io] [] []} {[*] [extensions] [thirdpartyresources] [] []} {[*] [extensions] [thirdpartyresources.extensions] [] []} {[*] [extensions] [ingresses] [] []} {[*] [] [configmaps] [] []} {[*] [] [endpoints] [] []} {[*] [] [pods] [] []} {[*] [] [services] [] []}] user=&{[email protected] [...] | ||
``` | ||
You need to add the following: (replace the name with your own) | ||
``` | ||
|
@@ -55,18 +55,19 @@ If not specify `namespace`, a randomly namespace would be generated for each tes | |
|
||
### For all the following example, you always need to add: | ||
* `--auth_enable` if you want to include auth | ||
* `--rbac_path=install/kubernetes/istio-rbac-beta.yaml` if you are using a rbac cluster (which means you disabled legacy if using GKE) | ||
* `--cluster_wide` if you want to run the cluster wide installation and tests | ||
* `--use_initializer` if you want to do transparent sidecar injection | ||
|
||
### Example | ||
From the repo checkout root directory | ||
|
||
* Run tests with the latest stable version of istio according to istio.VERSION : | ||
|
||
`tests/e2e.sh --rbac_path=install/kubernetes/istio-rbac-beta.yaml --auth_enable` | ||
`tests/e2e.sh --auth_enable` | ||
|
||
* Test commit in pilot repo, SHA:"dc738396fd21ab9779853635dd22693d9dd3f78a": | ||
|
||
`tests/e2e.sh --pilot_hub=gcr.io/istio-testing --pilot_tag=dc738396fd21ab9779853635dd22693d9dd3f78a --istioctl_url=https://storage.googleapis.com/istio-artifacts/dc738396fd21ab9779853635dd22693d9dd3f78a/artifacts/istioctl --rbac_path=install/kubernetes/istio-rbac-beta.yaml --auth_enable` | ||
`tests/e2e.sh --pilot_hub=gcr.io/istio-testing --pilot_tag=dc738396fd21ab9779853635dd22693d9dd3f78a --istioctl_url=https://storage.googleapis.com/istio-artifacts/dc738396fd21ab9779853635dd22693d9dd3f78a/artifacts/istioctl --auth_enable` | ||
|
||
* If you want to run one specific test, you can do: | ||
|
||
|
Oops, something went wrong.