prompt stringlengths 65 38.7k | response stringlengths 41 29.1k |
|---|---|
<p>I was just wondering, why it is useful to run etcd cluster <a href="https://github.com/kubernetes/charts/tree/master/incubator/etcd" rel="nofollow noreferrer">inside Kubernetes</a>, when Kubernetes itself <a href="https://kubernetes.io/docs/concepts/overview/components/#etcd" rel="nofollow noreferrer">depends on etc... | <p>If you're using Kubernetes via <a href="https://cloud.google.com/kubernetes-engine/" rel="nofollow noreferrer">GKE</a>, the underlying Etcd cluster is not exposed in any way.</p>
|
<p>Is there any way I can run container in k8s as root user or other user.
Like in docker </p>
<pre><code>docker run --user <user> <image>
</code></pre>
<p>Is there any yaml configuration for running with </p>
| <p>As described in the <a href="https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container" rel="noreferrer">kubernetes docs</a>, you can set the security context for the container and set the <code>runAsUser</code> property as such:</p>
<pre><code> containers:
... |
<p>It is possible to create a service that only points to a pod, created by a statefulset?</p>
<p>The solutions that make me would be:</p>
<ul>
<li>Put as a provider on behalf of the pod. </li>
<li>Dynamic labels with the name of the pod.</li>
</ul>
| <p>As per Kubernetes 1.9 you can use: statefulset.kubernetes.io/pod-name</p>
<p>From the documentation:</p>
<blockquote>
<p>"When the StatefulSet controller creates a Pod, it adds a label,
statefulset.kubernetes.io/pod-name, that is set to the name of the
Pod. This label allows you to attach a Service to a spec... |
<p>I'm very new to Kubernetes, I have deployed a cluster on Kubernetes. Created a deployment and set POD's count to 2. I didn't create HPA for this deployment.</p>
<p>I'm using Google Cloud for this. I enabled autoscaling for the cluster. min is 2 and max is 30.</p>
<p>I got the <strong>OOMKilled</strong> error in my d... | <p>You can use <code>kubectl</code> to change the number of pods running:</p>
<p><code>kubectl scale deployment <DEPLOYMENT NAME> --replicas=<#PODS></code>
<br>
<code>kubectl scale deployment student-app --replicas=2</code></p>
<p>You can find more info at the <a href="https://kubernetes.io/docs/reference/g... |
<p>I have worked on Kubernetes and currently reading about Service Fabric, I know Service Fabric provides microservices framework models like stateful, stateless and actor but other than that it also provides <code>GuestExecutables</code> or <code>Containers</code> as well which is what Kubernetes also does manage/orch... | <p>Caveat: as noted by <a href="https://stackoverflow.com/users/163341/joniba">joniba</a> in the comments, the original answer (see below) presents Fabric and Kubernetes are somehow similar, with the differences being nuanced.</p>
<p>That contasts with <a href="https://twitter.com/benmorrisuk/" rel="nofollow noreferrer... |
<ul>
<li>I have multiple kubernetes clusters running on GKE (let's say clusterA and clusterB)</li>
<li>I want to access both of those clusters from client-go in an app that is running in one of those clusters (e.g. access clusterB from an app that is running on clusterA)</li>
</ul>
<p>I general for authenticating with... | <p>client-go needs to know about:</p>
<ol>
<li>cluster master’s IP address</li>
<li>cluster’s CA certificate</li>
</ol>
<p>(If you're using GKE, you can see these info in <code>$HOME/.kube/config</code>, populated by <code>gcloud container clusters get-credentials</code> command).</p>
<p>I recommend you to either:</... |
<p>In kubernetes 1.8, when I create a deployment for example</p>
<pre><code>apiVersion: apps/v1beta2 # for versions before 1.8.0 use apps/v1beta1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
spec:
replicas: 3
selector:
matchLabels:
app: nginx
template:
metadata:
... | <p>When you create a deployment, the apiserver persists it and is capable of converting the persisted deployment into any supported version. </p>
<p><code>kubectl get deployments</code> actually requests the extensions/v1beta1 version (you can see this by adding --v=6)</p>
<p>To get apps/v1beta2 deployments, do <code... |
<p>I want to use existing AWS ALB for my kubernetes setup. i.e. I don't want alb-ingress-controller create or update any existing AWS resource ie. Target groups, roles etc. </p>
<p>How can I make ALB to communicate with Kubernetes cluster, henceforth passing the request to existing services and getting the response ba... | <p>You basically have to open a node port on the instances where the Kubernetes Pods are running. Then you need to let the ALB point to those instances. There are two ways of configuring this. Either via Pods or via Services.</p>
<p>To configure it via a <strong>Service</strong> you need to specify <code>.spec.ports[]... |
<p>I'm new to Kubernetes. With the help of Kubernetes documentation , I installed <code>minikube</code>(v0.24.1) and <code>kubectl</code> in my Windows machine. VirtualBox(Version 5.1.18) is also installed in my machine.</p>
<p>Before starting the <code>minikube</code>, i have executed <code>set HTTP_PROXY=xx.xx.xx:80... | <p>As @ivthillo already was pointing out, the issue may occur because you are behind a proxy. In this link they explain solutions to configure minikube when you are behind a proxy: <a href="https://github.com/kubernetes/minikube/issues/530#issuecomment-250801735" rel="nofollow noreferrer">https://github.com/kubernetes/... |
<p>I want to run my automation test script on kubernetes via the selenium hub and the chrome node containers.
My test script is also in the form of a container and running as a pod.
My test script uses localhost:4444 to connect to grid.
But the grid has the NodePort of 31376 and it keeps changing everytime i create a n... | <p>According to <a href="https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport" rel="nofollow noreferrer">the documentation on <code>NodePort</code> services</a></p>
<blockquote>
<p>If you want a specific port number, you can specify a value in the nodePort field, and the system will allocate y... |
<p>Using google Kubernetes engine:</p>
<pre><code>kubectl cluster-info
kubernetes-dashboard is running at https://x.x.x.x/api/v1/namespaces/kube-system/services/kubernetes-dashboard/proxy
</code></pre>
<p>If I go to the link:</p>
<p>I get to a forbidden page and if I accepts I get the following:</p>
<pre><code>{
... | <p>That url points to the Kubernetes API that requires authentication, and it's not the place to access the dashboard via web.</p>
<p>If you want to access the kubernetes dashboard, there are different options</p>
<ul>
<li>Use <a href="https://kubernetes.io/docs/tasks/access-application-cluster/web-ui-dashboard/#acce... |
<p>I have the following system in mind: A master program that polls a list of tasks to see if they should be launched (based on some trigger information). The tasks themselves are container images in some repository. Tasks are executed as jobs on a Kubernetes cluster to ensure that they are run to completion. The maste... | <p>Your master program can utilize the Kubernetes client libraries to preform operations on a cluster. Find a complete example <a href="https://github.com/kubernetes/client-go/tree/master/examples/in-cluster-client-configuration" rel="nofollow noreferrer">here</a>.</p>
|
<p>I have set up my Kubernetes 1.3.4 cluster on GCE with </p>
<p><code>export KUBE_ENABLE_CLUSTER_MONITORING=google</code></p>
<p>This works quite nicely, I get application logs (for some reason in the <em>Container Engine</em> section, but well) and also pod and node metrics.</p>
<p>The only thing that is missing a... | <p>If you are running your cluster using GCE instead of GKE
You should install the <a href="https://cloud.google.com/monitoring/agent/install-agent#linux-install" rel="nofollow noreferrer">stackdriver agent</a> and verify the credentials that agent is using to communicate with stackdriver <a href="https://cloud.google... |
<p>When a Kubernetes service is exposed via an <code>Ingress</code> object, is the load balancer "phisically" deployed in the cluster, i.e. as some <code>pod</code> controller inside the cluster nodes, or is just another managed service provisioned by the given cloud provider?</p>
<p>Are there cloud provider specific ... | <p>I would like to make some clarification concerning the Google Ingress Controller starting from its definition:</p>
<blockquote>
<blockquote>
<p>An Ingress Controller is a daemon, deployed as a Kubernetes Pod, that watches the apiserver's /ingresses endpoint for updates to the Ingress resource. Its job is to s... |
<p>I am new to jaeger and I am facing issues with finding the services list in the jaeger UI.</p>
<p>Below are the .yaml configurations I prepared to run jaeger with my spring boot app on Kubernetes using minikube locally.</p>
<p><code>kubectl create -f https://raw.githubusercontent.com/jaegertracing/jaeger-kubernete... | <p>Service graph data must be generated in Jaeger. Currently it's possible with via a Spark job here: <a href="https://github.com/jaegertracing/spark-dependencies" rel="nofollow noreferrer">https://github.com/jaegertracing/spark-dependencies</a></p>
|
<p>I am defining a kubernetes service like this:</p>
<pre><code>kind: Service
apiVersion: v1
metadata:
name: de-identity-svc
labels:
app: api-identity
environment: de
product: api
annotations:
service.beta.kubernetes.io/aws-load-balancer-additional-resource-tags: "app=api-identity,environment=de,... | <p>You should upgrade your server Kubernetes version to 1.9 or above, as NLB is only available for <a href="https://github.com/kubernetes/kubernetes/blob/master/CHANGELOG-1.9.md#aws" rel="nofollow noreferrer">Kubernetes 1.9 and up</a>. Please note that NLB is still in alpha, so you shouldn't use it for anything substan... |
<p>In this repository <a href="https://github.com/mappedinn/kubernetes-nfs-volume-on-gke" rel="nofollow noreferrer">https://github.com/mappedinn/kubernetes-nfs-volume-on-gke</a> I am trying to share a volume through NFS service on GKE. The NFS file sharing is successful if hard coded IP address is used. </p>
<p>But, i... | <p>The problem is in DNS resolution on node it self. Mounting of the NFS share to the pod is a job of kubelet that is launched on the node. Hence the DNS resolution happens according to /etc/resolv.conf on the node it self as well. What could suffice is adding a <code>nameserver <your_kubedns_service_ip></code> t... |
<p>How can an application running in a pod on Kubernetes cluster find the currently running number of pods of the same image (instances of the same image)? Is there also a way to uniquely identify each pod in a collection of pods of the same type?</p>
<p>For Eg. If I have 3 pods of the same image running in my Kuberne... | <p>If your application needs to know that information, you will need the following:</p>
<ul>
<li>Access the Kubernetes API from within your application and ask for the information. Depending on the language you are using, you can find different client libraries: <a href="https://github.com/kubernetes-client" rel="nofo... |
<p>I'm stepping through Kubernetes in Action to get more than just familiarity with Kubernetes.</p>
<p>I already had a Docker Hub account that I've been using for Docker-specific experiments.</p>
<p>As described in chapter 2 of the book, I built the toy "kubia" image, and I was able to push it to Docker Hub. I verif... | <p>You need to make sure the Docker daemon running in the Minikube VM uses your corporate proxy by starting minikube along these lines:</p>
<p><code>minikube start --docker-env http_proxy=http://proxy.corp.com:port --docker-env https_proxy=http://proxy.corp.com:port --docker-env no_proxy=192.168.99.0/24</code></p>
|
<p>I created a Pod that have <code>@EnableTaskLauncher</code> with <code>spring-cloud-deployer-kubernetes</code>. It is receiving task requests through <code>spring-cloud-stream</code> and launching the tasks.</p>
<p>Everything is working perfectly except that I want the task to be launched as <code>Kind: Job</code> i... | <p>We moved away from the Jobs to Bare-pods model for Spring Cloud Task (in SCDF) to better control its lifecycle such as the clean shutdown of the container when the SCT-operation is complete.</p>
<p>However, there's <a href="https://github.com/spring-cloud/spring-cloud-deployer-kubernetes/pull/163" rel="nofollow nor... |
<p>I have pod and its purpose is to take the incoming data and write it to the host volume. I'm running this pod in all the minions.</p>
<p>Now when i setup NodePort service to this pods, traffic will go to 1 pod at a time. </p>
<p>But how do i send request to all this pods in different minions? How to i bypass the l... | <p>Here's a method that works as long as you can send the requests from a container inside the k8s network (this may not match the OP's desire exactly, but I'm guessing this may work for someone googling this).</p>
<p>You have to look up the pods somehow. Here I'm finding all pods in the <code>staging</code> namespace... |
<p>I'm attempting to create a cluster on Google Kubernetes Engine that runs nginx, RStudio server and two Shiny apps, following and adapting <a href="https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer" rel="noreferrer">this guide</a>.</p>
<p>I have 4 workloads that are all green in the UI, deploye... | <p>the most likely problem you have is that when you go with this ingress you attached your URI is different then with direct accesc ( /shiny1/ vs / ) so your app is lost and has no content for that uri.</p>
<p>With Nginx Ingress Controller you can use <code>ingress.kubernetes.io/rewrite-target: /</code> annotation to... |
<p>I am using the Mirantis kubeadm-dind-cluster repository (<a href="https://github.com/Mirantis/kubeadm-dind-cluster" rel="nofollow noreferrer">https://github.com/Mirantis/kubeadm-dind-cluster</a>) as my Kubernetes install; I came across this error when attempting to run a container -</p>
<pre><code>panic: customreso... | <p>What version of kubectl are you using? Be sure you are using a version that includes the <code>kubectl create clusterrolebinding</code> command</p>
<p>If your version of kubectl does not support that command, you can try creating it directly via a yaml file (though I'm not sure whether 1.5.x kubectl was happy submi... |
<p>We are building workflow scheduling application. We found Airflow as a good option for workflow manager and Kubernetes as good option for Cluster manager. Thus, flow would be, </p>
<ol>
<li>We will submit workflow DAG to Airflow.</li>
<li>Airflow should submit the tasks of a given DAG to Kubernetes by specifying do... | <p>This is in flight right now. You just can follow along with <a href="https://issues.apache.org/jira/browse/AIRFLOW-1314" rel="noreferrer">this major jira ticket</a></p>
<p>One of the more stable branches (work is being led by a lot of this team) is located in the <a href="https://github.com/bloomberg/airflow/tree/a... |
<p>From what I understand, using multiple replicas as well as auto-scaling is supposed to help in the case that lots of people visit your website and make calls to services provided by your Kubernetes cluster.<br> </p>
<p>How do the replicas help with scaling?<br></p>
<p>Aren't these extra pods all just running on th... | <p>Kubernetes has couple of scaling mechanisms. Horizontal Pod Autoscaler being the basic, but not the only one.</p>
<p>With HPA you can spin up additional PODs according to some metrics (most commonly cpu and memory). At some point you will hit a moment when your cluster nodes do not have enough resources to satisfy ... |
<p>I'm attempting to run a 3-node Kubernetes cluster. I have the cluster up and running sufficiently that I have services running on different nodes. Unfortunately, I don't seem to be able to get NodePort based services to work correctly (as I understand correctness anyway...). My issue is that any NodePort services I ... | <p>When you define a NodePort service there are actually three ports in play:</p>
<ul>
<li>The container port: this is the port your pod is actually listening on, and it's only available when directly hitting your container from within the cluster, pod to pod (JIRA's default port would be 8080). You set the <code>targ... |
<p>I am trying to install kubernetes on ubuntu 16.04.
I am able to install other kubernetes components but i dont know if kube-proxy is installed? Should i get separate binary package for it or does it come prepackaged with kubernetes apt-get installation?</p>
| <p>In regular apt-get packages you would normally find kubectl, kubeadm and kubelet. If you use kubeadm to create the cluster it will automatically prepare kube-proxy as well (in the form of a container, as the rest of the elements of the kubernetes control panel). Therefore, you wouldn't need to install it separately.... |
<p>We have success creating the pods, services and replication controllers according to our project requirements. Now we are planning to setup persistence storage in AWS using Kubernetes. I have created the YAML file to create an EBS volume in AWS, it's working fine as expected. I am able to claim volume and successful... | <p>When you are using ReadWriteOnce volumes (ones that can not be mounted to multiple pods at the same time), simple PV/PVC creation will not cut it.</p>
<p>Both PV and PVC are pretty "singular" in a way that if you refer in Deployment to a particular claim name, your pods will all try to get the same one claim and th... |
<p>Is there a way to find the pod name for a given Docker container ID?</p>
<p>I can do it the other way round "kubectl describe pods" but then I have to run it on all the pods.</p>
| <p>Yes, you can get the pod name given a container ID using the following <code>kubectl</code> request:</p>
<pre><code>kubectl get pod -o jsonpath='{range .items[?(@.status.containerStatuses[].containerID=="docker://<container_id>")]}{.metadata.name}{end}' -n <namespace>
</code></pre>
<p>where <code><c... |
<p>I am trying to create an orient db deployment on kubernetes cluster using the following yaml file using the orientdb:2.125 docker image from docker hub.</p>
<pre><code>apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: orientdb
namespace: default
labels:
name: orientdb
spec:
replicas: 2
r... | <p>orientdb web application on port 2480 returns gzipped HTTP response, so you should add custom HTTP headers to support this into your <code>httpGet</code> livenessProbe and readinessProbe:</p>
<pre><code>livenessProbe:
httpGet:
path: /
port: http-port
httpHeaders:
- name: Accept-Encoding
valu... |
<p>We have a GKE cluster with:</p>
<ul>
<li>master nodes with version 1.6.13-gke.0</li>
<li>2 node pools with version 1.6.11-gke.0</li>
</ul>
<p>We have Stackdriver Monitoring and Logging activated.</p>
<p>On 2018-01-22, masters where upgraded by Google to version 1.7.11-gke.1.</p>
<p>After this upgrade, we have a ... | <p>First of all, the answer to question 2.</p>
<p>As alternatives we could have:</p>
<ul>
<li>filtered fluentd to ignore logs from fluentd-gcp pods OR</li>
<li>deactivate Stackdriver monitoring and logging</li>
</ul>
<p>To answer question 1:</p>
<p>We upgraded to 1.7.12 in a <strong>test environment</strong>. The p... |
<p>I am trying to install kubernetes on ubuntu 16.04.
I am able to install other kubernetes components but i dont know if kube-proxy is installed? Should i get separate binary package for it or does it come prepackaged with kubernetes apt-get installation?</p>
| <p>In most cases installing kube-proxy onthe node it self is not required as a common pattern is running kube-proxy as a DaemonSet in your kube cluster.</p>
|
<p>To start of I have tested the tutorial at <a href="https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer" rel="noreferrer">https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer</a></p>
<p>which works fine. I also tested the same tutorial but added a tls secret as well to test htt... | <p>Turned out our Angular application had a redirect on '/' which gave it a 302 response. This response makes the health check fail and results in a UNHEALTHY state.</p>
<p>As soon as we set up a custom health check it worked.</p>
|
<p>I'm new to Kubernetes and I'm learning. I have my Windows 8 machine where I installed Vagrant. Using vagrant I'm running ubuntu VM and inside that VM I'm running 3 docker containers.</p>
<p>Vagrant file:</p>
<pre><code>Vagrant.configure(2) do |config|
config.vm.box = "test"
config.vm.network "public_network"
... | <p>From what I see, you executed <code>minikube start</code> inside the Ubuntu VM. By default, this would try to download the minikube ISO and launch another VM (VM inside a VM) where minikube would be running. </p>
<p>I think that this nested virtualization is causing issues with your installation. If, for some reaso... |
<p>Is it possible to expose service ports with different policies like NodePort or ClusterIP.</p>
<p>For example we have </p>
<ul>
<li>some public XMPP API that should be accessible for end users</li>
<li>internal cluster API to communicate with other micro-services</li>
</ul>
<p>Right now I can create different ser... | <p>No, using two distinct services each of its own type is the right way to do it, and there is no harm/overhead in doing it like this</p>
|
<p>I am trying to use the Kubernetes 1.7.12 fluentd-elasticsearch addon:
<a href="https://github.com/kubernetes/kubernetes/tree/v1.7.12/cluster/addons/fluentd-elasticsearch" rel="noreferrer">https://github.com/kubernetes/kubernetes/tree/v1.7.12/cluster/addons/fluentd-elasticsearch</a></p>
<p>ElasticSearch starts up an... | <p>A few troubleshooting tips:</p>
<p>1) ensure ElasticSearch is running fine.</p>
<p>Enter the container running elasticsearch and run:</p>
<p><code>curl localhost:9200</code></p>
<p>You should get a JSON, with some data about elasticsearch.</p>
<p>2) ensure ElasticSearch is reachable from the kibana container</p... |
<p>How do I create groups in kubernetes?
What are the default groups created in kubernetes?</p>
<p>In my kubernetes installation, this is the subject section of a ClusterRoleBinding:</p>
<pre><code>subjects:
- apiGroup: rbac.authorization.k8s.io
kind: Group
name: default
- apiGroup: rbac.authorization.k8s.io
ki... | <p>you dont create groups in Kubernetes, but the groups are defined in the Identity Provider.</p>
<p>For example I use Keystone from Openstack as the Identity provider. I use a Bearer Token to login, and Kubernetes validates the token connecting to Keystone, that answers with my username and my project UUID in Opensta... |
<p>I'm interested in getting started with Kubernetes, but my needs are simple and it does not look simple. I have a number of containerized applications that I deploy to container servers. I use nginx as a reverse proxy to expose these applications.</p>
<p>As far as I can tell, Kubernetes is meant to simplify manageme... | <p>As you want to get started with Kubernetes, I assume that you want to set-up for your local development, I think that <a href="https://github.com/kubernetes/minikube" rel="nofollow noreferrer">minikube</a> is a best candidate for this purpose. You can also take a look at interactive <a href="https://kubernetes.io/do... |
<p>According to <a href="https://docs.traefik.io/user-guide/kubernetes/" rel="nofollow noreferrer">Traefik's Kubernetes guide</a>, I should use a Service of type <strong>NodePort</strong> to expose Traefik (YAML file <a href="https://github.com/containous/traefik/blob/master/examples/k8s/traefik-deployment.yaml" rel="n... | <p>Both are valid approaches. The Kubernetes guide basically makes one proposal to set things up (with somewhat of a focus on the local minikube configuration). If you have found a path that's more convenient for you, by all means feel free to stick to it.</p>
<p>FWIW, one concern I sometimes hear raised is that cloud... |
<p>I'm interested in getting started with Kubernetes, but my needs are simple and it does not look simple. I have a number of containerized applications that I deploy to container servers. I use nginx as a reverse proxy to expose these applications.</p>
<p>As far as I can tell, Kubernetes is meant to simplify manageme... | <ol>
<li>On developers machine; you should use minikube.</li>
<li>On Azure / Google / Amazon ..etc; you should use managed kubernetes services</li>
<li><p>On Prem you should deploy kubernetes with on your own setup.</p>
<p>3.1. <a href="https://github.com/kelseyhightower/kubernetes-the-hard-way" rel="nofollow norefer... |
<p>I want to deploy a DaemonSet for monitoring purpose. So these Pods need to be deployed in all Nodes.</p>
<blockquote>
<p>A DaemonSet ensures that all (or some) Nodes run a copy of a Pod.</p>
</blockquote>
<p>I am using a DaemonSet so that all nodes get a copy.</p>
<pre><code> spec:
containers:
- ... | <p>Since Kubernetes 1.6, DaemonSets do not schedule on master nodes by default. In order to schedule it on master, you have to add a toleration into the Pod spec section:</p>
<pre><code>tolerations:
- key: node-role.kubernetes.io/master
effect: NoSchedule
</code></pre>
<p>For more details, check out the example YAM... |
<p>I have a cluster in aws and using kubernetes.
I have an app running on a machine (vm) in the same network as the cluster
in my browser i can type <a href="http://ipaddress:port/status" rel="nofollow noreferrer">http://ipaddress:port/status</a> and i get a response</p>
<p>In my pod i can ping the ip address and i ge... | <p>You can integrate external services within kubernetes.
<p>endpoint.yaml</p>
<pre><code> kind: Endpoints
apiVersion: v1
metadata:
name: external-ip-database
subsets:
- addresses:
- ip: 192.168.0.1
ports:
- port: 3306
</code></pre>
<p>service.yaml</p>
<pre><code> ap... |
<p>I am trying to pull the image from the ECR repository inside the Kubernetes cluster, but I am not able to do this.</p>
<p>I tried creating a secret and updated in the pod file, but I am not able to do this I am getting an error "no basic auth credentials".</p>
<p>Please can anyone give me the step by step instruct... | <p>Your problem may be caused by the fact that ECR credentials work only for 12 hours, so maybe you are trying to use expired credentials. </p>
<p>I recommend you to have a look at <a href="https://github.com/upmc-enterprises/registry-creds" rel="nofollow noreferrer">upmc-enterprises/registry-creds</a>. This tool can ... |
<p>I have a deployment config for an app, that (among other things) creates a secret for a mysql database:</p>
<pre><code>---
apiVersion: v1
kind: Secret
metadata:
name: mysql-secret
type: Opaque
data:
MYSQL_USER: my_user
MYSQL_PASSWORD: my_random_secret
MYSQL_DATABASE: my_db
MYSQL_ROOT_PASSWORD: my_random_s... | <p>As far I have understood that you do not want to keep your secret information locally. So that you need to generate them when you are creating that secret.</p>
<p>I think there is a way to create Kubernetes resource using go-template. Didn't find enough information for that. I can't help you in this way.</p>
<p>Bu... |
<p>We have success creating the pods, services and replication controllers according to our project requirements. Now we are planning to setup persistence storage in AWS using Kubernetes. I have created the YAML file to create an EBS volume in AWS, it's working fine as expected. I am able to claim volume and successful... | <p>Horizontal Pod Autoscaler can scale only Deployment, Replica Set or Replication Controller. You cannot scale Stateful Sets. (see <a href="https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale-walkthrough/" rel="nofollow noreferrer">Kubernetes Docu for more details</a>)</p>
<p>The main reason is ... |
<p>I am new to RabbitMQ and I have troubles when handling RabbitMQ cluster.</p>
<p>The topology is like:</p>
<p><a href="https://i.stack.imgur.com/srHSW.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/srHSW.png" alt="enter image description here"></a></p>
<p>At first, every is ok. RabbitMQ node1 a... | <p>You set <code>cluster_partition_handling</code> to <code>pause_minority</code>. One out of two nodes isn't the majority, so the cluster stops as configured. You either have to add an additional node or set <code>cluster_partition_handling</code> to <code>ignore</code>.</p>
<p>From the <a href="https://www.rabbitmq.... |
<p>We have a Kubernetes cluster of web scraping cron jobs set up. All seems to go well until a cron job starts to fail (e.g., when a site structure changes and our scraper no longer works). It looks like every now and then a few failing cron jobs will continue to retry to the point it brings down our cluster. Running <... | <p>You can tell your Job to stop retrying using <code>backoffLimit</code>.</p>
<blockquote>
<p>Specifies the number of retries before marking this job failed.</p>
</blockquote>
<p>In your case</p>
<pre><code>spec:
template:
spec:
containers:
- name: scrape-al
image: 'govhawk/openstate... |
<p>I recently followed the official guide to setup <a href="https://github.com/heketi/heketi/blob/master/doc/admin/install-kubernetes.md" rel="nofollow noreferrer">Heketi</a> on Kubernetes. Everything works fine, except that whenever I create a drive smaller than 2GB it automatically creates a 2GB PV. I couldn't find a... | <p>The minimum volume size created by Heketi is 1GB.</p>
<p>The units followed in heketi(currently) is in terms of GBs and hence for example, when you create volume of size 1.8GB it creates 2GB volume.</p>
|
<p>Been googling it for a while and can't figure out the answer: suppose I have two containers inside a pod, and one has to send the other some secrets. Should I use https or is it safe to do it over http? If I understand correctly, the traffic inside a pod is firewalled anyway, so you can't eavesdrop on the traffic fr... | <p>Containers inside a Pod communicate using the loopback network interface, localhost.</p>
<p>TCP packets would get routed back at IP layer itself, if the address is localhost.</p>
<blockquote>
<p>It is implemented entirely within the operating system's networking software and passes no packets to any network inte... |
<p>I've been developing an app on my local laptop (Mac) with Minikube. Instead of packaging the code and files into the docker image, I use <code>hostPath</code> and <code>volumeMount</code> that points to the code/file directory on my Mac, so that I can avoid rebuilding the image every time. </p>
<p>Now I would like ... | <p><strong>You want:</strong>
You want to mount your local file system into your remote Kubernetes cluster.</p>
<p><strong>Answer:</strong>
As far I know, you can't do this. Its possible in <code>minikube</code>, because, you can mount your local directory with <code>minikube</code>. </p>
<p><strong>Solution:</stron... |
<p>I have install the Grafan in my Kubenernetes 1.9 cluster. When I access with my ingress URL (<a href="http://sample.com/grafana/" rel="noreferrer">http://sample.com/grafana/</a> ) getting the first page. After that javascript, css download not adding /grafana to the URL.</p>
<p>here is my ingress rule:</p>
<pre><... | <p>Your ingress rule is correct and nginx creates correct virtual host to forward traffic to grafana's service (I left only needed strings to show):</p>
<pre><code> server {
server_name sample.com;
listen 80;
listen [::]:80;
set $proxy_upstream_name "-";
location ~* ^/grafana/(?<baseuri>.*) ... |
<p>I am trying to schedule Jobs in Kubernetes.</p>
<p><a href="https://kubernetes.io/docs/concepts/workloads/controllers/cron-jobs/" rel="nofollow noreferrer">https://kubernetes.io/docs/concepts/workloads/controllers/cron-jobs/</a></p>
<p>The job can be created using the below command.</p>
<pre><code>$ kubectl creat... | <p>The respective REST endpoint is described in <a href="https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.17/#cronjob-v1beta1-batch" rel="nofollow noreferrer">the official API reference</a>. You will find the <code>CronJob</code> resource in the <code>batch/v1beta1</code> API group. To create a new <cod... |
<p>Does anyone know how to connect a local instance of <code>kubectl</code> to a Google Kubernetes Engine (GKE) cluster, without using the <code>gcloud</code> tool locally?</p>
<p><strong>For example:</strong></p>
<p>If you use the <code>gcloud</code> tool with this command:</p>
<pre><code>gcloud container clusters ... | <p>The easiest way to achieve this is by copying the <code>~/.kube/config</code> file (from a gcloud authenticated instance) to this directory <code>$HOME/.kube</code> in your local instance (laptop). </p>
<p>But first, and using the authenticated instance, you would have to enable legacy cluster per this <a href="htt... |
<p>Jenkins ver. 2.77
K8s Version: v1.6.6"</p>
<p>We have installed the Jenkins Kubernetes Plugin and configured it to work with our K8s Cluster.
We are able to succesfully connect to the cluster when we test our connection via
“Manage Jenkins” -> “Configure System” -> Cloud, Kubernetes.</p>
<p>Our Template c... | <p>your issue maybe the command and arguments.</p>
<p>the command should be blank, and the arguments should be set to:</p>
<p>${computer.jnlpmac} ${computer.name}</p>
<p>this will allow the jnlp slave to connect to the jenkins master correctly</p>
|
<p>I am trying to access my Kubernetes cluster on google cloud with the service account, but I am not able to make this works. I have a running system with some pods and ingress. I want to be able to update images of deployments. </p>
<p>I would like to use something like this (remotely): </p>
<pre><code>kubectl con... | <p>I have tried to recreate your problem.</p>
<p>Steps I have followed</p>
<ul>
<li><code>kubectl create serviceaccount foo</code></li>
<li><code>kubectl get secret foo-token-* -o yaml</code></li>
</ul>
<p>Then, I have tried to do what you have done</p>
<p><strong>What I have used</strong> as token is <code>base64</cod... |
<p>I have been working with docker to run my scripts on chrome-node and firefox -node and debug with the selenium-hub image where it runs smoothly, but when I use the same with k8s the whole system slows down. Why is this happening, any idea. I am using minikubes for kubernetes and docker toolbox and docker compose for... | <p>There would definitely be an additional overhead when you start Kubernetes using minikube locally, compared to just starting a Docker container on the host.</p>
<p>In order to have a Kubernetes cluster, minikube creates a VM on the machine where the Kubernetes components will run in addition to the Docker container... |
<p>I am running minikube v0.24.1. In this minikube, I will create a Pod for my nginx application. And also I want to pass data from my local directory.</p>
<p>That means I want to mount my local <code>$HOME/go/src/github.com/nginx</code> into my Pod</p>
<p>How can I do this?</p>
<pre><code>apiVersion: v1
kind: Pod
m... | <p>You can't mount your local directory into your Pod directly.</p>
<p>First, you need to mount your directory <code>$HOME/go/src/github.com/nginx</code> into your minikube.</p>
<pre><code>$ minikube start --mount-string="$HOME/go/src/github.com/nginx:/data" --mount
</code></pre>
<p>Then If you mount <code>/d... |
<p>I have a Kafka cluster running on Kubernetes (on AWS). Each broker has a corresponding external loadbalancer (ELB) and afaict, Kafka's <code>advertised.listeners</code> have been set appropriately so that the ELB's DNS names get returned when clients query for broker information. Most of the setup is similar to the ... | <p>Marking the coordinator dead happens when there is a Network communication error between the Consumer Client and the Coordinator (Also this can happen when the Coordinator dies and the group needs to rebalance). There are a variety of situations (offset commit request, fetch offset, etc) that can cause this issue. S... |
<p>I'm trying to deploy a persistent storage for couch DB and it is failing out with the error</p>
<hr />
<p>kubectl create -f couch_persistant_deploy.yaml</p>
<blockquote>
<p>error: error validating "couch_persistant_deploy.yaml": error validating data: couldn't find type: v1.Deployment; if you choose to ign... | <p>Your error message should be like this:</p>
<blockquote>
<p>error: error validating "couch_persistant_deploy.yaml": error validating data: ValidationError(Deployment.spec.template.spec.volumes[0]): unknown field "claimName" in io.k8s.api.core.v1.Volume; if you choose to ignore these errors, turn ... |
<p>I have an application on GKE that I wish to be available via HTTPS only, so I have gotten a signed certificate to secure the application using TLS.</p>
<p>I have checked out a lot of tutorials on how I can do this, but they all refer to using Ingress and automatically requesting the certificate using, LetsEncrypt a... | <p>Ingress is probably your best bet when it comes to exposing your application over HTTPS. The Ingress resource specifies a backend service, so you will to continue exposing your application as a Kubernetes service, just with type set to <code>ClusterIP</code>. This will produce a service that is "internal" to your cl... |
<p>I wish I could have found my answer elsewhere, but the lack of documentation has sent me groveling for help :)</p>
<p>I have been following <a href="https://cloud.google.com/kubernetes-engine/docs/tutorials/http-balancer" rel="nofollow noreferrer">this tutorial</a> as a starting point. I can follow the steps throug... | <p>GKE has its own Ingress Controller. It is called GKE Ingress Controller. If you want to use Nginx Ingress Controller, you need to manage it yourself.</p>
<p>Looks like <code>auth-url annotation</code> works only on Nginx Ingress Controller. So, you have to run Nginx Ingress Controller first.</p>
<p>See <a href="ht... |
<p>I did this example <a href="https://github.com/jetstack/kube-lego/tree/master/examples/gce" rel="noreferrer">https://github.com/jetstack/kube-lego/tree/master/examples/gce</a> , then failed to create ClusterRole kube-lego.</p>
<p>The error is:</p>
<pre><code>Error from server (Forbidden): error when creating "k8s/... | <p>As commented in <a href="https://github.com/jetstack/kube-lego/issues/225#issuecomment-313412762" rel="noreferrer"><code>kube-lego</code> issue 225</a>:</p>
<blockquote>
<p>Turns out the error I was receiving in an known issue with GKE 1.6. I resolved by following this article:</p>
<h2>get current google identity</h... |
<p>I am wondering if egress policies can be set for external domains that are not part of the K8s namespace or K8s cluster. We have a usecase where we set the default policy of a namespace to deny all outgoing traffic and we then write egress and ingress rules for each application.</p>
<p>Some of these applications ne... | <p>You can limit the egress IPs using <a href="https://kubernetes.io/docs/concepts/services-networking/network-policies" rel="nofollow noreferrer">network policies</a>. But it isn't possible to declare egress DNS names. </p>
|
<p>I am not able to create Kubernetes Dashboard.</p>
<p>I am following the steps mentioned in Kubernetes official <a href="https://kubernetes.io/docs/tasks/access-application-cluster/web-ui-dashboard/" rel="nofollow noreferrer">website</a>:</p>
<pre><code>kubectl create -f https://raw.githubusercontent.com/kubernetes... | <p>You need a cluster with RBAC enabled, otherwise the installation will fail because it can't find the <code>Role</code> kind of object. To enable RBAC, start the apiserver with <code>--authorization-mode=RBAC</code>.</p>
|
<p>Following blog post <a href="http://blog.kubernetes.io/2017/05/managing-microservices-with-istio-service-mesh.html" rel="nofollow noreferrer">here</a> I am trying to deploy this sample service on my aws k8s through istio gives me "error: no objects passed to apply"</p>
<p><strong>Setup</strong></p>
<ul>
<li>aws k8... | <p>It probably means that <code>istioctl kube-inject</code> produced empty output in the <code>istioctl kube-inject -f book-info-v1.yaml</code> part. Try to run <code>istioctl kube-inject -f book-info-v1.yaml</code> as a separate command and see if it produces any errors.</p>
|
<p>I have installed a cluster on Google Kubernetes Engine. </p>
<p>And then, I created namespace "staging"</p>
<pre><code>$ kubectl get namespaces
default Active 26m
kube-public Active 26m
kube-system Active 26m
staging Active 20m
</code></pre>
<p>Then, I switched to operate in the stagin... | <p>As your cluster is RBAC enabled, seems like your <code>tiller</code> Pod do not have enough permission.</p>
<p>You are using <code>default</code> ServiceAccount which lacks enough RBAC permission, tiller requires.</p>
<p>All you need to create ClusterRole, ClusterRoleBinding and ServiceAccount. With them you can p... |
<p>I see advantages of Kubernetes which include Rolling Deployments, Automatic Health check monitoring, and swinging a new server to action when an existing one fails. I also do understand that Kubernetes is not just for Docker. </p>
<p>So, that brings a couple of questions! </p>
<p>When Azure, and Service Fabric ... | <p>Let's look first at the similarities between Kubernetes and Service Fabric. </p>
<ul>
<li>They are both cloud-agnostic clustering, orchestration, and scheduling software.</li>
<li>They can both be deployed manually, by you, to any set of VMs, anywhere.</li>
<li>There are "managed" offerings for both, meaning a clou... |
<p>This might be very basic question but I can't find anywhere so I apologize..</p>
<p>I have installed postresql using helm on Google Kubernetes Engine</p>
<pre><code>$ helm install --name staging stable/postgresql
</code></pre>
<p>My deployments:</p>
<pre><code>$ kubectl get deployments
NAME DESIR... | <p>In Kubernetes you have two options to find IP of your service.</p>
<ol>
<li>Environment variables</li>
</ol>
<p>Kubernetes generates automatically environment variables with all the data you need to access a service. If you run <code>env</code> command inside a pod, then you should see similar output to:</p>
<pre... |
<p>This is my application code:</p>
<pre><code>from flask import Flask
from redis import Redis, RedisError
import os
import socket
# Connect to Redis
redis = Redis(host=os.getenv("REDIS", "redis"), db=0, socket_connect_timeout=2, socket_timeout=2)
app = Flask(__name__)
@app.route("/")
def hello():
try:
... | <p>There is a discrepancy between your <code>wishful-rabbit-mychart-master-svc</code> service's <code>Selector</code> and your master redis pods' <code>labels</code>.</p>
<p>Your service is searching for pods with the following labels:</p>
<pre><code>app=redis-ha
redis-node=true
redis-role=master
release=wishful-rabb... |
<p>We are using RC to run our workload and want to migrate to Deployment. Is there a way to do that with out causing any impact to the running workload. I mean, can we move these running pods under Deployment? </p>
| <p>Like, @matthew-l-daniel answered, the answer is yes. But I am more than 80% certain about it. Because I have tested it</p>
<p>Now whats the process we need to follow</p>
<p>Lets say I have a ReplicationController.</p>
<pre><code>apiVersion: v1
kind: ReplicationController
metadata:
name: nginx
spec:
replicas: ... |
<p>I have a web app hosted in the Google Cloud platform that sits behind a load balancer, which itself sits behind an ingress. The ingress is set up with an SSL certificate and accepts HTTPS connections as expected, with one problem: I cannot get it to redirect non-HTTPS connections to HTTPS. For example, if I connect ... | <p>The problem was indeed the fact that the Nginx Ingress is not standard on the Google Cloud Platform, and needs to be installed manually - doh!</p>
<p>However, I found installing it to be much more difficult than anticipated (especially because my needs pertained specifically to GCP), so I'm going to outline every s... |
<p>Kubernetes' liveness and readiness probes for pods (deployment) can be configured with this initial delay ---- meaning the probe will start after this many seconds after the container is up. If it is not specified, what is the default value? I can't seem to find it. The default value for periodSeconds is documented ... | <p>It seems that the default value of <code>0</code> is missing from the <a href="https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/#configure-probes" rel="noreferrer">documentation</a>.</p>
<p>The health or readiness check algorithm works like this:</p>
<ol>
<li>Wait ... |
<p>Use case:</p>
<p>I have a NFS directory available and I want to use it to persist data for multiple deployments & pods.</p>
<p>I have created a <code>PersistentVolume</code>:</p>
<pre class="lang-yaml prettyprint-override"><code>apiVersion: v1
kind: PersistentVolume
metadata:
name: nfs-pv
spec:
capacity:
... | <p>Basically you can't do what you want, as the relationship PVC <--> PV is one-on-one. </p>
<p>If NFS is the only storage you have available and would like multiple PV/PVC on one nfs export, use Dynamic Provisioning and a default storage class. </p>
<p>It's not in official K8s yet, but this one is in the incubato... |
<p>I'm running Kubernetes 1.2.0 on a number of lab machines. The machines have swap enabled. As the machines are used for other purposes, too, I cannot disable swap globally.</p>
<p>I'm observing the following problem: If I start a pod with a memory limit, the container starts swapping after it reached the memory limi... | <p>Kubernetes, specifically the <code>kubelet</code>, <a href="https://github.com/kubernetes/kubernetes/commit/f4edaf2b8c32463d6485e2c12b7fd776aef948bc" rel="nofollow noreferrer">fails if swap is enabled on Linux since version <code>1.8</code> (flag <code>--fail-swap-on=true</code>)</a>, as <a href="https://github.com/... |
<p>I have a docker image called docker-hello-world - all it does is print Hello World to the log using the JRE. When tested it works fine.</p>
<p>Then, I import an image into Kubernetes Docker and run – still no issues.</p>
<pre><code>docker images -a
REPOSITORY TAG ... | <p>The version tag of the image <code>docker-hello-world:latest</code> is <code>latest</code>, which indicates the default <code>ImagePullPolicy</code> is <code>Always</code> (see <code>pkg/apis/core/v1/defaults.go</code> for v1.9.x and after). It will try to pull image from the hub and not use the image already presen... |
<p>Using:</p>
<pre><code>kubectl expose deployment <Name-Of-Servce> --name=loadbalancer --port=8080 --target-port=8080 --type=LoadBalancer
</code></pre>
<p>The <code>kubectl get services</code> is showing pending:</p>
<pre><code>loadbalancer LoadBalancer <x.x.x.x> <pending> 808... | <p>Both type LoadBalancer and NodePort work on Docker for Mac Kubernetes. It's a lovely bit of magic, actually. Just hit localhost:[port]. For NodePort, a port is automatically assigned unless specified in the service definition. For type LoadBalancer, it is also specified in the service definition. Note that in using ... |
<p>Deploying my service to production:</p>
<pre><code>envsubst < ./kubernetes/pre-production/aks.yaml | kubectl apply -f -
</code></pre>
<p>I'm getting the following error:</p>
<blockquote>
<p>The Deployment "moverick-mule-pre" is invalid:
spec.template.metadata.labels: Invalid value:
map[string]string{"com... | <p>You need to add <code>selector</code> in <code>spec</code> of Deployment.</p>
<p>And also, these <code>selector</code> should match with <code>labels</code> in PodTemplate.</p>
<pre><code>apiVersion: apps/v1beta1
kind: Deployment
metadata:
name: moverick-mule-pre
spec:
replicas: 2
selector:
matchLabels:
... |
<p>I am currently deploying my applications in a Kubernetes cluster using Helm. Now I also need to be able to modify some parameter in the values.yaml file for different environments.</p>
<p>For simple charts with only one level this is easy by having different values-local.yaml and values-prod.yaml and add this to th... | <p>Here is how I would do it (for reference <a href="https://docs.helm.sh/chart_template_guide/#overriding-values-from-a-parent-chart" rel="noreferrer" title="overriding values">overriding values</a>):</p>
<ol>
<li>In your child charts (foochart) define the number of replicas as a variable:
<ul>
<li>foochart/values.y... |
<p>Today I met a strange issue about my Windows kubectl client suddenly raise authorization issue in connecting ICp.</p>
<p>I was using ICP with a Widows configured kubectl.exe. Then, after a while, due to laptop automatic sleeping, my VPN connection was disconnected, hence lose connection to remote ICP. Later I came... | <p>It turns out that the tokens was invalid (not sure if it because of 12 hours expiration). If you simply F5 the browser page you didn't re-authenticated but still can access the console page, but actually the token should be updated by re-login ICP Portal again.</p>
<p>The issue was fixed by re-access the ICP portal... |
<p><strong>Is is possible to rename a PVC?</strong> I can't seem to find an evidence it is possible.</p>
<hr>
<p>I'm trying mitigate an "No space left of device" issue I just stumbled upon. Essentially my plan requires me to resize the volume, on which my service persists its data.</p>
<p>Unfortunately I'm still on ... | <p>The answer of your question is <strong>NO</strong>. There is no way to change any meta name in Kubernetes.</p>
<p>But, there is a way to fulfill your requirement.</p>
<p>You want to claim your new <em>bigger</em> PersistentVolume by old PersistentVolumeClaim.</p>
<p>Lets say, old PVC named <code>victim</code> and... |
<p>I have a single instance Redis Deployment/Service on my cluster:</p>
<p><strong>Redis.yaml</strong></p>
<pre><code>---
apiVersion: v1
kind: Service
metadata:
name: myapp-redis
labels:
name: myapp-redis
spec:
ports:
- port: 6379
targetPort: 6379
selector:
name: myapp-redis
---
apiVersion: v... | <p>The <em>connection refused</em> error was caused by the redis configuration.</p>
<p>I had to change the redis host from <em>localhost</em> to <code>0.0.0.0</code> in order to allow external connections.</p>
<p>In <code>redis.conf</code> I changed this line:</p>
<pre><code>bind 127.0.0.1
</code></pre>
<p>to this:</p>... |
<p>I have two services, web-service is running on port 80 and admin-service is running on port 8000. I'd like all http /admin requests to be proxied to admin-service:8000 and all other requests to go to web-service:80. I've tried the configuration below but it doesn't seem to work. I'm also using Google Kubernetes Engi... | <p>looks good, but... does your admin service respond to <code>GET /admin</code> ? cause unless you use <code>ingress.kubernetes.io/rewrite-target: /</code> annotation on your ingress, you need to support the URI in your backing service</p>
|
<p>it’s been driving me crazy for about a week now. Searched over the “whole” internet with no luck. used rexray, standard config, digital ocean setup etc.</p>
<p>Cannot make it working on digital ocean with block storage.
Would be great if anyone could point me to some tutorial (preferable official kubernetes storage... | <p>Kubernetes does not support Volume plugin for DigitalOcean.</p>
<p>But you can use this using FlexVolume plugin as external storage.</p>
<ul>
<li>Digital Ocean Flex Plugin</li>
<li>Digital Ocean External Provisioner</li>
</ul>
<p>See this <a href="https://github.com/kubernetes/kubernetes/pull/50044#issuecomment-3... |
<p>I'm looking to redirect all traffic from </p>
<p><a href="http://example.com" rel="noreferrer">http://example.com</a> -> <a href="https://example.com" rel="noreferrer">https://example.com</a> like how nearly all websites do.</p>
<p>I've looked at this link with no success:
<a href="https://stackoverflow.com/questi... | <p>GKE uses GCE L7. The rules that you referenced in the example are not supported and the HTTP to HTTPS redirect should be controlled at the application level.</p>
<p>L7 inserts the <code>x-forwarded-proto</code> header that you can use to understand if the frontend traffic came using HTTP or HTTPS. Take a look here:... |
<p>I am trying to create windows nodes in an already existing kubernetes cluster in Azure. The kubernetes cluster has two Linux nodes running on them. </p>
<p>I am trying to use az aks cli to create windows nodes but I don't see any option.</p>
<p>So can we create Linux and Windows nodes in the same kubernetes cluste... | <p>Yes, this is posible, but not using the CLI\portal (at this stage). You need to use <a href="https://github.com/Azure/acs-engine" rel="nofollow noreferrer">ACS engine</a>.</p>
<p>You need to use this definition (adjust it to your needs):<br>
<a href="https://github.com/Azure/acs-engine/blob/master/examples/windows/... |
<p>In IBM Cloud Private EE, I need to go to the Web UI <code>User > Configure client</code>, copy the <code>kubectl</code> config commands and then run these 5 commands on my client machine. </p>
<p>I deployed the IBM Cloud private EE on 5 VMs and have access to the master node. I am wondering if there is a way to ... | <p>You should use <strong><a href="https://www.vagrantup.com/" rel="nofollow noreferrer">Vagrant</a></strong> to automate those steps.</p>
<p>For instance, <a href="https://github.com/IBM/deploy-ibm-cloud-private/blob/ba600e9c08d5bd9fd784e1b209a07ef597052a7f/Vagrantfile#L659-L666" rel="nofollow noreferrer"><code>IBM/d... |
<p>I am trying to install Kubernetes 1.9.0 on a cluster of CentOS 7.3 systems running in VMware Workstation on Windows 7, following the "kubernetes-the-hard-way tutorial". When I get to the verification stage in the tutorial and try to start the busybox deployment (<a href="https://github.com/kelseyhightower/kubernetes... | <p>The syntax for this in <code>daemon.json</code> is </p>
<pre><code>"insecure-registries" : ["gcr.io" , "googleapis.com"]
</code></pre>
<p>"Also depending of the registries you are accessing, you may have to perform a "<code>kubectl create secret docker-registry ...</code>" action as explained <a href="https://kub... |
<p>I'm following <a href="https://cloud.google.com/kubernetes-engine/docs/tutorials/migrating-node-pool" rel="nofollow noreferrer">this guide</a> in an attempt to upgrade a kubernetes cluster on GKE with no downtime. I've gotten all the old nodes cordoned and most of the pods have been evicted, but for a couple of the ... | <p>The helm chart you linked contains a PodDisruptionBudget (PDB). <code>kubectl drain</code> will not remove pods if it would violate a PDB (reference: <a href="https://kubernetes.io/docs/concepts/workloads/pods/disruptions/" rel="nofollow noreferrer">https://kubernetes.io/docs/concepts/workloads/pods/disruptions/</a>... |
<p>I have installed kubernetes with minikube in ubuntu 16.04.
I want to know how i can integrate openid-connect based authentication with it. I am new to kubernetes. So any suggestion on how to configure would help.
I am currently accessing the dashboard with "minikube dashboard" command. But i dont seem to find any r... | <p>The <a href="https://kubernetes.io/docs/admin/authentication/" rel="nofollow noreferrer">Kubernetes Authentication</a> docs try to explain the different "<code>authn</code>" plugins. One of these is "OpenID Connect", which requires that you start up an "Identity Provider".</p>
<p>So when you tell <code>kubectl</co... |
<p>Is there a simple way to get the current attached volume state (think "space left on disk", or the opposite) ? Using stackdriver, this info is not provided. Not to be found neither within the gcloud console. I was wondering if this was accessible besides connecting to the instance and check it manually</p>
| <p>Check <a href="https://github.com/prometheus/prometheus" rel="nofollow noreferrer">Prometeus</a>.</p>
<p>At the moment this option is available through Kubernetes, but merely for the 1.8 version on.
As you can check <a href="https://github.com/coreos/prometheus-operator/issues/485" rel="nofollow noreferrer">here</a... |
<p>I have read the docs, but seem not able to understand differences between Mixer and Pilot. Is there any overlap? I mean I would like to draw a definite boundary between them to understand their responsibilities and with respect to their communication with the envoy proxies in the mesh. Please add examples of differe... | <p>The Istio Service Mesh provides the following functionalities:</p>
<ol>
<li>Routing. For example 90% of the traffic goes to the version 1 of a
microservice and the remaining 10% goes to the version 2. Or some
specific requests go to the version 1 and all the others to the
version 2, according to some condition. And... |
<p>I have a Django app and use Celery for background tasks. </p>
<p>For deploying, I use Docker with Kubernetes.</p>
<p>Deployment is automatized with Jenkins.</p>
<p>All is good, however I feel like this can be drastically optimized.</p>
<p>The problem is that Jenkins builds almost the same images for a django app... | <p>An option that comes to mind is to have the same entrypoint for all the images and then, using environment variables for example, have a logic in the entrypoint code that will launch one program or the other. Here's an extremely simple example.</p>
<pre><code>if [ $ROLE == "worker" ];then
program_1
else
pro... |
<p>In Kubernetes, it is possible to make a service running in cluster externally accessible by running <code>kubectl expose deployment</code>. Why deployment as opposed to service is beyond my simpleton's comprehension. That aside, I would like to also be able to undo this operation afterwards. Think of a scenario, ... | <p>Assuming you have a deployment called hello-world, and do a kubectl expose as follows:</p>
<p><code>kubectl expose deployment hello-world --type=ClusterIP --name=my-service</code></p>
<p>this will create a service called my-service, which makes your deployment accessible for debugging, as you described.</p>
<p>To... |
<p>We're running <code>gitlab-runner</code> instances via kubernetes executors inside a kubernetes cluster (let's call it KUBE01). These instances build and deploy to the kubernetes cluster, and runners are given an environment variable <code>KUBECONFIG</code> (pointing to a config file) as follows:</p>
<pre><code>$ c... | <p>After a more detailed reading of the <a href="https://kubernetes.io/docs/admin/authentication/#service-account-tokens" rel="noreferrer">kuberneter authentication documentation</a> and some trial and error, I have found the issue.</p>
<p>The "secret tokens" inside service account objects are not the <em>actual</em> ... |
<p>Is there a way to limit the number of deployments a Kubernetes cluster will implement at once? With rolling deployments and 100% uptime, it's possible that updating all deployments at once could overload the nodes.</p>
<p>I know it is possible to limit the number of pods deployed per-namespace, but i was wondering ... | <p>The first thing coming to my mind is to use resource <a href="https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#resource-types" rel="nofollow noreferrer">limits and requests</a> to make sure you're not overloading the cluster. This way, even if you update all the deployments, some... |
<p>I created a cluster using kops. It worked fine and the cluster is healthy. I can see my nodes using kubectl and have created some deployments and services. I tried adding a node using "kops edit ig nodes" and got an error "cluster not found". Now I get that error for all kops commands:</p>
<pre><code>kops vali... | <p>My KOPS_STATE_STORE environment variable got messed up. I corrected it to be the correct s3 bucket and everything is fine.</p>
<pre><code>export KOPS_STATE_STORE=s3://correctbucketname
</code></pre>
|
<p>In kubernetes, master node provide kube-apiserver process to accept REST API requests. What about ICp? can we use curl command to quickly test k8s REST APIs on ICp master node as well?</p>
| <p>The answer is yes. But first you may need to pay attention to the default port for --insecure-port and --secure-port. By default, if you didn't change it in config.yaml file, ICp use below ports to accept REST requests:</p>
<p>--insecure-port=8888</p>
<p>--secure-port=8001</p>
<pre><code>netstat -anp|grep 8888
</... |
<p>My goal is to filter access by IP address of an angular app deployed on Kubernetes Engine served by nginx through a GCE ingress.</p>
<p>But on my nginx the remote_addr is not right.</p>
<p><strong>$LB_IP is the ip defined here : kubernetes.io/ingress.global-static-ip-name: app-angular</strong></p>
<p>I'm usin... | <p>They are two solutions (Thks to gcbirzan for helping me on GCP slack):</p>
<p><strong>1) Update My nginx configuration with the good IPS from IP addresses ranges :</strong></p>
<p>IP addresses ranges can be found here : <a href="https://console.cloud.google.com/networking/networks/list" rel="nofollow noreferrer... |
<p>I have a kubernetes cluster with a gitlab-runner 10.3.0 and kubernetes executor. There is no <code>cache_dir</code> defined in the runner's config.toml-file. Note that this is different that a docker executor, so the volume-solutions do not apply.</p>
<p>In a <code>.gitlab-ci.yml</code>, I configured a job to use t... | <p>Due to the distributed nature of Kubernetes, you will need to configure a central cache location (typically, in the form of a S3-compatible object storage like <a href="https://aws.amazon.com/s3" rel="nofollow noreferrer">AWS S3</a> or <a href="https://www.minio.io/" rel="nofollow noreferrer">Minio</a>). The reason ... |
<p>I am trying to deploy a tomcat docker container in the Kubernetes and start the application deployed. </p>
<p>I have installed tomcat inside the docker container and copied my application war file in the tomcat webapps folder. When i ssh into the docker container and tried to start the tomcat server by running the ... | <p>This issue was happening because of lack of memory for the Node. In my case it is Minikube which is acting as a Node. After i allotted more memory to minikube, i am able to deploy and start my application from tomcat docker container.</p>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.