#!/bin/bash # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. set -xe # This restarts minikube with podsecuritypolicy admission controller enabled sudo -E minikube stop sleep 10 sudo -E minikube start \ --docker-env HTTP_PROXY="${HTTP_PROXY}" \ --docker-env HTTPS_PROXY="${HTTPS_PROXY}" \ --docker-env NO_PROXY="${NO_PROXY},10.96.0.0/12" \ --extra-config=kubelet.network-plugin=cni \ --extra-config=controller-manager.allocate-node-cidrs=true \ --extra-config=controller-manager.cluster-cidr=192.168.0.0/16 \ --extra-config=apiserver.enable-admission-plugins=PodSecurityPolicy # NOTE: Wait for node to be ready. kubectl wait --timeout=240s --for=condition=Ready nodes/minikube