1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2024-12-14 11:57:48 +00:00
kyverno/scripts
2019-06-10 18:10:51 -07:00
..
compile-image.sh change project name in compile-image script to kyverno 2019-05-21 13:40:17 -07:00
create-test-configmap.sh NK-21: Added checking request by selector. Added tests for this logic. Added test policy file for selectors. 2019-02-28 18:43:20 +02:00
deploy-controller-debug.sh Allow user to run Kyverno in debug mode 2019-06-10 18:10:51 -07:00
deploy-controller.sh - Change kube-policy to kyverno in install.yaml - Install in namespace kyverno 2019-05-21 18:36:24 -07:00
generate-self-signed-cert-and-k8secrets-debug.sh Allow user to run Kyverno in debug mode 2019-06-10 18:10:51 -07:00
generate-self-signed-cert-and-k8secrets.sh move client to pkg, helper script for self-signed certs & update documentation 2019-05-29 14:12:09 -07:00
generate-server-cert.sh Implemented test webhook, fixed script for certificate generation, fixed project dependencies 2019-02-21 18:13:21 +02:00
README.md - Change kube-policy to kyverno in install.yaml - Install in namespace kyverno 2019-05-21 18:36:24 -07:00
test-web-hook.sh NK-8: Implemented deployment script for free (local) and in-cluster usage of the controller. Added readme file for scripts, improved scripts: implemented more convenient way to pass arguments. Removed hardcode from server.go. 2019-02-13 19:57:18 +02:00
update-codegen.sh Made update-codegen script crossplatform 2019-05-13 21:24:02 +03:00

Use these scripts to prepare the controller for work. All these scripts should be launched from the root folder of the project, for example: scripts/compile-image.sh

compile-image.sh

Compiles the project to go executable, generates docker image and pushes it to the repo. Has no arguments.

generate-server-cert.sh

Generates TLS certificate and key that used by webhook server. Example: scripts/generate-server-cert.sh --service=kyverno-svc --namespace=my_namespace --serverIp=192.168.10.117

  • --service identifies the service for in-cluster webhook server. Do not specify it if you plan to run webhook server outside the cluster, or cpecify 'localhost' if you want to run controller locally.
  • --namespace identifies the namespace for in-cluster webhook server. Do not specify it if you plan to run controller locally.
  • --serverIp is the IP of master node, it can be found in ~/.kube/config: clusters.cluster[0].server. You should explicitly specify it.

deploy-controller.sh

Prepares controller for free (local) or in-cluster use. Uses generate-server-cert.sh inside and has the same parameters with almost same meaning:

  • --service - the name of the service which will be created for the controller. Use 'localhost' value to deploy controller locally. The default is 'kube-policu-svc'
  • --namespace - the target namespace to deploy the controller. Do not specify it if you want to depoloy controller locally.
  • --serverIp means the same as for generate-server-cert.sh Examples: scripts/deploy-controller.sh --service=my-kyverno --namespace=my_namespace --serverIp=192.168.10.117 - deploy controller to the cluster with master node '192.168.10.117' to the namespace 'my_namespace' as a service 'my-kyverno' scripts/deploy-controller.sh --service=localhost --serverIp=192.168.10.117 - deploy controller locally for usage in cluster with mnaster node at '192.168.10.117'

test-web-hook.sh

Quickly creates and deletes test config map. If your webhook server is running, you should see the corresponding output from it. Use this script after deploy-controller.sh.

update-codegen.sh

Generates additional code for controller object. You should resolve all dependencies before using it, see main Readme for details.