prompt stringlengths 65 38.7k | response stringlengths 41 29.1k |
|---|---|
<p>I know it's possible to access the static views of the api, but I can't find out the basic auth details that I need to login via the browser. Where can I find these? I'm on GCE and created a cluster.</p>
| <p>Run <code>kubectl config view</code>. It'll dump out the auth information used to access your cluster, including the basic auth username and password.</p>
|
<p>Some time ago I asked about handling thousands of services in a Kubernetes cluster:</p>
<p><a href="https://stackoverflow.com/questions/27638334/can-kubernetes-handle-thousands-of-services">Can Kubernetes handle thousands of services?</a></p>
<p>At that time Kubernetes was using env vars and my question was more o... | <p>The shortcoming mentioned in the documentation has not changed, because Kubernetes still uses the same mechanism (iptables and a userspace proxy) for proxying traffic sent to a service IP to the pods backing the service.</p>
<p>However, I don't believe we actually know how bad it is. A team member briefly tried tes... |
<p>What does "level-based" and "edge-based" mean in general?</p>
<p>I read "In other words, the system's behavior is level-based rather than edge-based" from kubernetes documentation:
<a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api-conventions.md" rel="noreferrer">https://github.com/Go... | <p>It also has a more general definition (at least the way we tend to use it in the documentation). A piece of logic is "level based" if it only depends on the current state. A piece of logic is "edge-based" if it depends on history/transitions in addition to the current state.</p>
<p>"Level based" components are more... |
<p>I'm using Google Container Engine with a cluster using <em>Kubernetes 0.20.2</em>.</p>
<p>In this cluster, I have <em>1 replication controller (2 replicas)</em> and <em>1 service</em> with a spec type defined to <strong><em>LoadBalancer</em></strong> (basic setup).</p>
<p>Everything is working fine here;
Then I wa... | <p>The <code>--update-period</code> flag tells Kubernetes how long to wait between each pod that it's rolling an update to. With the update period set to 0, Kubernetes will update all pods at once, causing a short period of unavailability while the new pods start up. You should set <code>--update-period</code> to be at... |
<p>I've just installed a kubernetes testinstallation directly on my fedora laptop using <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/v0.18.2/docs/getting-started-guides/fedora/fedora_manual_config.md" rel="nofollow">this guide</a>.</p>
<p>After starting kube2sky I've noticed I can't connect to the k... | <p>This has been a common problem for folks that aren't running on setups that use salt to automatically configure system secrets on the master node (as GCE does). This has been fixed at head and should be fixed in the next release. </p>
<p>In the mean time, you can manually create a secret for the DNS service that co... |
<p>If I have a multi - tier application (say web / logic / database), where each tier having it's own container, and I need to deploy all of these en - bloc, do they all have to go into the same pod?</p>
<p>And if they are in the same pod, does this have any implications in terms of the maximum size of application tha... | <p>Why do you need to deploy all of the components together? In a micro services architecture, you would want to reduce the dependencies between each layer to a clean interface and then allow each layer to be deployed and scaled separately from the others. </p>
<p>If you need to deploy them together (e.g. they share l... |
<p>We would like to spin up pods quickly on our cluster, to handle 'one-off' tasks (the idea being that each task has a new pod every time it runs).</p>
<p>Currently, it takes about 10-15 seconds from a Pod creation API call -> completion. This is running on 3x m3 xlarge on AWS, with images that have already been cach... | <p>Our target is 5s latency from creation -> Running (assuming image is pre-pulled). The issue tracking this was <a href="https://github.com/GoogleCloudPlatform/kubernetes/issues/3954" rel="nofollow">https://github.com/GoogleCloudPlatform/kubernetes/issues/3954</a>.</p>
<p>This issue was closed a couple weeks ago, so ... |
<p>I want to set the hostname in a container running inside Kubernetes, but Kubernetes appears to be overriding whatever I set at runtime.</p>
<p>I've tried both setting /etc/hostname in the docker image I'm having Kubernetes use, and including <code>echo "host.example.com > /etc/hostname"</code> in the CMD in the ... | <p>My previous answer was incorrect, edited with correct info</p>
<p>The <code>-h</code> flag for <code>docker run</code> will set the hostname of the container when you create it.</p>
<p>Test it out: <code>docker run -h test.example.com -it ubuntu /bin/bash</code></p>
<p>The <code>docker start</code> command does n... |
<p>We want to test kubernetes load balancing. So we create a 2 node cluster thats runs 6 replicas of our container. Container has running apache2 server and php and it will print pod name if we browse hostname.php</p>
<p><strong>Cluster details:</strong>
172.16.2.92 -- master and minion
172.16.2.91 -- minion</p>
<p><... | <p>Because flannel is not working properly so do </p>
<blockquote>
<p>/root/kube/reconfDocker.sh on everynode</p>
</blockquote>
<p>it will restart the docker and flannel then check the ifconfig docker0 and flannel0 bridge IPs should be in same network. Then load balancing will work. It works for me.</p>
|
<p>I'm trying to understand a good way to handle Kubernetes cluster where there are several nodes and a master.
I host the cluster within the cloud of my company, plain Ubuntu boxes (so no Google Cloud or AWS).</p>
<p>Each pod contains the webapp (which is stateless) and I run any number of pods via replication contro... | <p>The PublicIP thing is changing lately and I don't know exactly where it landed. But, services are <em>the</em> ip address and port that you reference in your applications. In other words, if I create a database, I create it as a pod (with or without a replication controller). I don't connect to the pod, however, f... |
<p>A few kubernetes novice questions. </p>
<p>If I got it right when a kubernetes cluster its setup the size ita defined with the number of minions that want to be in the cluster, lets say I create a cluster with two minions. If I decide to deploy 4 pods with a php and nginx serving it. </p>
<p>There its a way I can ... | <p>See the <a href="http://kubernetes.io/v1.0/docs/user-guide/compute-resources.html" rel="noreferrer">Compute Resources</a> section of the kubernetes user guide. It describes how to assign cpu and memory limits on your containers and how the scheduler places them in your cluster. </p>
<p>As you scale up the number o... |
<p>I have followed the installation steps:
<a href="https://cloud.google.com/container-engine/docs/tutorials/guestbook#install_gcloud_and_kubectl" rel="noreferrer">https://cloud.google.com/container-engine/docs/tutorials/guestbook#install_gcloud_and_kubectl</a></p>
<p>A Google Container Engine cluster is up and runnin... | <p>Run</p>
<p><code>gcloud container clusters get-credentials my-cluster-name</code></p>
<p>to update the kubeconfig file and point kubectl at a cluster on Google Container Engine.</p>
|
<p>Assume the following stack:</p>
<ul>
<li>A dedicated server</li>
<li>The server is running Vagrant</li>
<li>Vagrant is running 2 virtual machines master + minion-1 (Kubernetes)</li>
<li>minion-1 is running a pod</li>
<li>Within the pod is 2 containers: webservice and fileservice</li>
</ul>
<p>Both webservice and f... | <p>The easiest thing for you to do at the moment is to make a service of type "nodePort", and to configure your HAproxy to point at minion-1:.</p>
<p>createExternalLoadBalancer is the old, less flexible, way to do this--it requires the cloud provider to do work. Type=nodePort doesn't require anything special from the ... |
<p>When I run the Kubernetes vagrant setup script:</p>
<pre><code>export KUBERNETES_PROVIDER=vagrant
curl -sS https://get.k8s.io | bash
</code></pre>
<p>I get:</p>
<pre><code>Validating master
Validating minion-1
Waiting for each minion to be registered with cloud provider
error: couldn't read version from server: ... | <p>It looks like issue is gone, I've tried one more time and installation went flawlessly: </p>
<p><img src="https://i.stack.imgur.com/TLPwG.png" alt="enter image description here"></p>
|
<p>I'm trying to spin up a Kubernetes (k8s) cluster on GCE. When I run</p>
<pre><code>gcloud components update kubectl
</code></pre>
<p>on a Windows machine I get</p>
<blockquote>
<p>ERROR: (gcloud.components.update) The following components are unknown [kubectl]</p>
</blockquote>
| <p>Update (May 2016): As of <a href="https://cloud.google.com/container-engine/release-notes#march_29_2016" rel="nofollow">late March 2016</a>, gcloud will now install kubectl for windows. </p>
<hr>
<p>gcloud won't currently install kubectl on windows (hence the error). You can download a recent kubectl binary direct... |
<p>I am trying to use CircleCI to automate my push to the google container registry and initiate a rolling update of the kubernetes pods. I have a <code>circle.yml</code> file with dependencies like this:</p>
<pre><code>dependencies:
cache_directories:
- ~/kubernetes
- ./google-cloud-sdk
pre:
- chmod a... | <p>The recommended way to install the Cloud SDK non-interactively is to set the environment variable <code>CLOUDSDK_CORE_DISABLE_PROMPTS</code>:</p>
<pre><code>export CLOUDSDK_CORE_DISABLE_PROMPTS=1
</code></pre>
<p>This will make the Cloud SDK run in non-interactive mode, in which it accepts the default value for al... |
<p>I'm trying to update a service using :</p>
<pre><code>kubectl update service my-service \
--patch='{ "apiVersion":"v1", "spec": { "selector": { "build":"2"} } }'
</code></pre>
<p>I receive the following Error :
<code>Error from server: service "\"apiVersion\":\"v1\"," not found</code></p>
<p>I have tried the ... | <p>I am not sure if patch is 100% working yet, but if you are going to do this, you at least need to put apiVersion inside metadata, like so:</p>
<p>--patch='{ metadata:{ "apiVersion":"v1" }, "spec": { "selector": { "build":"2"} } }'</p>
|
<p>I can get Pods information using <a href="http://localhost:8001/api/v1/pods" rel="nofollow">http://localhost:8001/api/v1/pods</a> from inside my cluster.</p>
<p>Is there any way to get pod informations using <a href="http://master-public-ip:8001/api/v1/pods" rel="nofollow">http://master-public-ip:8001/api/v1/pods</... | <p>By default, the master only exposes HTTPS to the public internet, not HTTP. You should be able to hit <code>https://admin:password@master-public-ip/api/v1/pods/</code>, where <code>password</code> is the generated password for the admin user. This can be found either in the <code>.kube/config</code> file on your mac... |
<p>I deployed apiserver on master node (core01) with following conf:</p>
<pre><code>core01> /opt/bin/kube-apiserver \
--insecure_bind_address=127.0.0.1 \
--insecure_port=8080 \
--kubelet_port=10250 \
--etcd_servers=http://core01:2379,http://core02:2379,http://core03:2379 \
--service-cluster-ip-range=10.1.... | <p>The first two lines of the kubelet log file actually point to the underlying problem -- you aren't specifying any client credentials for the kubelet to connect to the master. </p>
<p>The <code>--tls-cert-file</code> and <code>--tls-private-key-file</code> arguments for the kubelet are used to configure the http ser... |
<p>As per <a href="https://stackoverflow.com/questions/31573402/error-couldnt-read-version-from-server">this question</a>, I was wondering if there are any plans to be able to use the kubectl tool without installing gcloud?</p>
<p>The use case I have in mind is the same as the one that fellow had: <a href="https://git... | <p>You can definitely use kubectl without gcloud. You can download the latest official Kubernetes release from its <a href="https://github.com/GoogleCloudPlatform/kubernetes/releases" rel="nofollow">releases page on Github</a>, then run kubectl by untarring it and either running <code>./cluster/kubectl.sh</code> or cop... |
<p>Batch computations, Monte Carlo, using Docker image, multiple jobs running on Google cloud and managed by Kubernetes. But it (replication controller, I guess?) managed to restart same computation again and again due to default restart policy.</p>
<p>Is there a way now to let pods die? Or maybe other workarounds to ... | <p>Now that v1.0 is out, better native support for getting the batch computations is one of the team's top priorities, but it is already quite possible to run them.</p>
<p>If you run something as a pod rather than as a replication controller, you can set the <a href="https://github.com/GoogleCloudPlatform/kubernetes/b... |
<p>I'm getting started with Kubernates and having problems installing Postgres using Kubernetes with a GCE Persistent disk.
I can successfully install Mysql using both the Kubernates walkthroughs and also the following guide: <a href="http://amygdala.github.io/kubernetes/2015/01/13/k8s1.html" rel="nofollow">http://amy... | <p>I'm getting the same problem as well - it's due to the db initialization script wrongly assuming a non-empty volume directory means it has already been initialized.</p>
<p>Unfortunately, a new GCE persistence disk contains a <code>lost+found</code> directory.</p>
<p>I've submitted a fix for the docker image <a hre... |
<p>This is my first attempt to install and use Kubernetes. I am trying to install an environment on Mac for developing my own apps and deploying them for test locally with Kubernetes. I am familiar with using Vagrant, VirtualBox and Docker for the same purpose. When I saw this page <a href="https://github.com/GoogleClo... | <p>If you just want to kick the tires with Kubernetes, I'd recommend installing <a href="http://boot2docker.io" rel="nofollow">boot2docker</a> and then following the <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/release-1.0/docs/getting-started-guides/docker.md" rel="nofollow">Running kubernetes local... |
<p>I am trying to set up a HTTP load balancer for my Meteor app on google cloud. I have the application set up correctly, and I know this because I can visit the IP given in the Network Load Balancer.</p>
<p>However, when I try and set up a HTTP load balancer, the health checks always say that the instances are unheal... | <p>In order to use HTTP load balancing on Google Cloud with Kubernetes, you have to take a slightly different approach than for network load balancing, due to the current lack of built-in support for HTTP balancing.</p>
<p>I suspect you created your service in step 3 with <code>type: LoadBalancer</code>. This won't wo... |
<p>I would like to create a kubernetes pod that contains 2 containers, both with different images, so I can start both containers together.</p>
<p>Currently I have tried the following configuration:</p>
<pre><code>{
"id": "podId",
"desiredState": {
"manifest": {
"version": "v1beta1",
"id": "podId"... | <p>Your pod spec file looks like invalid.
According to <a href="http://kubernetes.io/v1.0/docs/user-guide/walkthrough/README.html#multiple-containers" rel="nofollow">http://kubernetes.io/v1.0/docs/user-guide/walkthrough/README.html#multiple-containers</a>, a valid multiple containers pod spec should like this</p>
<pre... |
<p>This is my first attempt to install and use Kubernetes. I am trying to install an environment on Mac for developing my own apps and deploying them for test locally with Kubernetes. I am familiar with using Vagrant, VirtualBox and Docker for the same purpose. When I saw this page <a href="https://github.com/GoogleClo... | <p>I don't yet know the fix but I know what is going wrong since it happens to me as well:</p>
<ul>
<li>OS X 10.10.3</li>
<li>Vagrant 1.7.4</li>
<li>VirtualBox 4.3.30</li>
<li>Kubernetes 1.0.1</li>
</ul>
<p>When I run the default configuration of this (which creates one "master" and one "minion" VM) I see that the st... |
<p>I'm very interesting in the new Google Cloud Service: Google Container Engine, namely in be a able to write systems that can scale using containers' properties.</p>
<p>I saw the StackOverflow questions:</p>
<ul>
<li><a href="https://stackoverflow.com/questions/26899789/autoscaling-in-google-container-engine">Autos... | <p>It's worth noting that you can now do both Autoscaling and Resize a running Google Container Engine Cluster by using Instance Groups - <a href="https://cloud.google.com/compute/docs/instance-groups/" rel="nofollow">https://cloud.google.com/compute/docs/instance-groups/</a> </p>
|
<p>Batch computations, Monte Carlo, using Docker image, multiple jobs running on Google cloud and managed by Kubernetes. No Replication Controllers, just multiple pods with NoRestart policy delivering computed payloads to our server. So far so good. Problem is, I have cluster with <code>N</code> nodes/minions, and have... | <p>Just for the record, after discussion with Alex, trial and error and a binary search for a good number, what worked for me was setting the CPU resource limit in the Pod JSON to:</p>
<pre><code> "resources": {
"limits": {
"cpu": "490m"
}
}
</code></pre>
<p>I have no idea how and w... |
<p>I am getting the following error when trying to run <code>kubectl</code> locally.</p>
<p><code>error: couldn't read version from server: Get http://localhost:8080/api: dial tcp 127.0.0.1:8080: connection refused</code></p>
<p>I know this relates to the kubectl config but I'm at a loss in how to resolve it. 2 days... | <p><strong>tl;dr</strong> <code>gcloud container get-credentials --cluster=CLUSTER_ID --zone=YOURZONE</code></p>
<hr>
<p>So a little background: the kubectl tool is developed by google but isn't actually integrated into google cloud directly, the google cloud just helps you get a compatible version with it when you t... |
<p>I am trying to see if there are any example to create a Kubernetes POD
which starts 2-3 containers and these containers are linked with each other but couldn't find any.</p>
<p>Does anybody tried linking containers using Kubernetes config.</p>
| <p>The containers in same pod shares the localhost, so you need not link containers, just use localhost:containerPort.</p>
|
<p>Batch computations, Monte Carlo, using Docker image, multiple jobs running on Google cloud and managed by Kubernetes. No Replication Controllers, just multiple pods with NoRestart policy delivering computed payloads to our server. So far so good. Problem is, I have cluster with <code>N</code> nodes/minions, and have... | <p>Yes, you can have them all ask for a resource of which there's only one on each node, then the scheduler won't be able to schedule more than N at a time. The most common way to do this is to have each pod ask for a <a href="https://github.com/kubernetes/kubernetes/blob/9030f16071f4f6d46f0482995f0db5eaf96b9294/pkg/ap... |
<p>As part of scaling pods in kubernetes I want to ensure I gracefully serve my http connections before shutting down. To that extent I have implemented this code in go:</p>
<pre><code>package main
import (
"fmt"
"io"
"net/http"
"os"
"os/signal"
"syscall"
"github.com/braintree/manners"
)
... | <p>You should use a readiness check (<a href="http://kubernetes.io/v1.0/docs/user-guide/production-pods.html#liveness-and-readiness-probes-aka-health-checks" rel="nofollow noreferrer">http://kubernetes.io/v1.0/docs/user-guide/production-pods.html#liveness-and-readiness-probes-aka-health-checks</a>)</p>
<p>that transit... |
<p>Can someone please explain the advantages/disadvantages using the following when building container images, rather than using the dockerfile.</p>
<ol>
<li><p>Packer - tool for creating machine and container images for multiple platforms from a single source configuration</p></li>
<li><p>Dockramp - A Client-driven ... | <ol>
<li><p>Packer is a tool that initially was created to create AWS AMIs or base VM images in AWS. It has been extended to be used with containers, a lot of different Virtualization software such as <a href="https://www.vmware.com" rel="nofollow">VMware</a>, <a href="http://wiki.qemu.org/KVM" rel="nofollow">KVM/QEMU<... |
<p>I successfully deployed Kubernetes on AWS using "getting started on AWS ec2 guide" (<a href="http://kubernetes.io/v1.0/docs/getting-started-guides/aws.html" rel="nofollow">http://kubernetes.io/v1.0/docs/getting-started-guides/aws.html</a>), but the disk size of all the minions (kubernetes hosts) is 8gb. I would lik... | <p>I recently stumbled upon the same issue. Have a look at BLOCK_DEVICE_MAPPINGS in <code>kubernetes/cluster/aws/util.sh</code>. You can modify it to have something more appropriate for a EBS-only minion. </p>
<p>For example:</p>
<pre><code>[{"DeviceName":"/dev/sda1","Ebs":{"VolumeSize":80}}]
</code></pre>
<p>AWS do... |
<p>Is there any known approach with which we can manage the Kubernetes cluster from a dashboard kind of UI? Kubernetes by default comes up with a UI which is good enough to view the details of running pods, services etc. </p>
<p>But what is the approach if we need to modify some properties of Kubernetes cluster (<em>l... | <p>The UI that runs by default in Kubernetes doesn't currently support modifying anything running in the cluster, and there aren't any other official UIs that do. It's something that we'd definitely like to improve in the future.</p>
<p>However, the fabric8 folks have put together a console that does allow you to chan... |
<p>I am running a Kubernetes cluster on Google container engine. My metrics are not getting pushed to Stackdriver by default.</p>
<p>Do I need to start Heapster service explicitly or is it automatically managed by container engine itself?</p>
| <p>If there isn't a Heapster pod running in your cluster, then your cluster was created before we started enabling cluster monitoring by default. </p>
<p>We are working on adding a way for users to retroactively turn on monitoring, but if you want metrics pushed into stack driver today you will need to create a new cl... |
<p>Have Kubernetes computation cluster running on GCE, reasonable happy so far. I know if I created K-cluster, I'll get to see nodes as VM Instances and cluster as Instance group. I would like to do other way around - create instances/group and make K-cluster out of it so it could be managed by Kubernetes. Reason I wan... | <p>There is a patch out for review at the moment (#<a href="https://github.com/GoogleCloudPlatform/kubernetes/pull/12384" rel="nofollow">12384</a>) that makes a configuration option to mark the nodes in the instance group as preemptible. If you are willing to build from head, this should be available as a configuration... |
<p>Kubernetes create a load balancer, for each service; automatically in GCE. How can I manage something similar on AWS?</p>
<p>Kubernetes service basically use the kubeproxy to handle the internal traffic. But that kubeproxy ip its do not have access to the external network. </p>
<p>There its a way to accomplish thi... | <p>In your service definition, set its <code>type</code> <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/7a3891e5f8819456b355750c0603e48da35b895b/pkg/api/v1/types.go#L1097" rel="noreferrer">field</a> to <code>LoadBalancer</code>, and kubernetes will automatically create an AWS Elastic Load Balancer for ... |
<p>Is probe frequency customizable in liveness/readiness probe?</p>
<p>Also, how many times readiness probe fails before it removes the pod from service load-balancer? Is it customizable?</p>
| <p>The probe frequency is controlled by the <code>sync-frequency</code> command line flag on the Kubelet, which defaults to syncing pod statuses once every 10 seconds.</p>
<p>I'm not aware of any way to customize the number of failed probes needed before a pod is considered not-ready to serve traffic.</p>
<p>If eithe... |
<p>A newly created Kubernetes cluster on GKE is not pushing its metrics to Stackdriver. Output of <code>kubectl cluster-info</code> is:</p>
<pre><code>Kubernetes master is running at https://XXX.XXX.XXX.XXX
KubeDNS is running at https://XXX.XXX.XXX.XXX/api/v1/proxy/namespaces/kube-system/services/kube-dns
KubeUI is ru... | <p>What Heapster does with the metrics depends on its configuration. When running as part of GKE, the metrics aren't exported as "custom" metrics, but rather as official GKE service metrics. The feature is still in an experimental, soft-launch state, but you should be able to access them at <a href="http://app.google.s... |
<p>I'm trying to mount several secrets in the same secret-volume for a kubernetes pod blueprint, but it's not accepted.</p>
<p>Tried and can't be created :</p>
<pre><code>"spec": {
"volumes": [
{
"name": "secret-volume",
"secret": [
{ "secretName": "se... | <p>Only one secret is allowed per secret volume</p>
|
<p>I have two service, S1 in cluster K1 and S2 in cluster K2. They have different hardware requirements. Service S1 needs to talk to S2.</p>
<p>I don't want to expose Public IP for S2 due to security reasons. Using NodePorts on K2 cluster's compute instances with network load-balancing takes the flexibility out as I w... | <p>I can think of a couple of ways to access services across multiple clusters connected to the same GCP private network:</p>
<ol>
<li><p>Bastion route into k2 for all of k2's services:</p>
<p>Find the <code>SERVICE_CLUSTER_IP_RANGE</code> for the k2 cluster. On GKE, it will be the <code>servicesIpv4Cidr</code> field... |
<p>I followed the official <a href="http://kubernetes.io/v1.0/docs/getting-started-guides/fedora/fedora_manual_config.html">Kubernetes installation guide</a> to install Kubernetes on Fedora 22 severs. Everything works out for me during the installation .</p>
<p>After the installation. I could see all my nodes are up-r... | <p>The ServiceAccount admission controller prevents pods from being created until their service account in their namespace is initialized.</p>
<p>If the controller-manager is started with the appropriate arguments, it will automatically populate namespaces with a default service account, and auto-create the API token ... |
<p>I ran into some trouble getting an external ip address after posting the following json object (variables excluded):</p>
<pre><code>$json= '{
"kind": "Service",
"apiVersion": "v1",
"metadata": {
"name": ""
},
"spec": {
"ports": [{
... | <p>After manually removing the Forwarding Rules Under "Networking->Load Balancing->Network Load Balancing" (Or you can use <code>gcloud compute forwarding-rules delete</code>) I was able to get public Ip's again. It seems somehow the forwarding rules werent deleted and reached the limit. It is strange as when I ran <co... |
<p>On this page in the Kubernetes docs <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/user-guide/pods.md" rel="noreferrer">Pods</a>, it states</p>
<blockquote>
<p>The context of the pod can be defined as the conjunction of several Linux namespaces:</p>
<p>PID namespace (applications... | <p>Yeah, we wish that they could share the PID namespace, but as you say, it is not currently supported by Docker. Once we have support in Docker, we will rapidly add it to Kubernetes.</p>
<p>This means that you can't use signal to signal other processes in the Pod.</p>
<p>You can, however, use IPC mechanisms like p... |
<p>I Have the following setup in mind:
Kubernetes on Mesos (based on the kubernetes-mesos project) within a /16 network.
Each pod will have its own IP and I believe this will avail 64 000 pods.
The idea is to provide isolation for each app i.e. Each app gets its own mysql within the same pod - the app accesses mysql on... | <p>A common misconception is that a Pod should manage a vertical, multi-tier stack: for example a web tier + DB tier together.</p>
<p>It's interesting to read the <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/user-guide/pods.md#uses-of-pods" rel="nofollow">Kubernetes design intent of Pods... |
<p>I want to use kubernetes as my default development environment for that I set up the cluster locally with docker as explained in the <a href="http://kubernetes.io/v1.0/docs/getting-started-guides/docker.html" rel="nofollow noreferrer">official doc</a>. I push my example to a <a href="https://github.com/bitgandtter/k... | <p>The issue was on the volume definition, the hostPath.path property should hold the absolute address of the directory to mount.</p>
<p>Example:</p>
<pre><code>hostPath:
path: /home/bitgandtter/Documents/development/php/k8s_devel_env
</code></pre>
|
<p>I am trying to build my image using this plugin: <a href="https://github.com/spotify/docker-maven-plugin#use-a-dockerfile">https://github.com/spotify/docker-maven-plugin#use-a-dockerfile</a></p>
<p>When I run <code>mvn clean package docker:build</code></p>
<p>I get this error:</p>
<pre><code>[ERROR] Failed to exe... | <p>So this regular expression: <code>[a-z0-9]+(?:[._-][a-z0-9]+)*</code> doesn't include any upper case letters. So you should change your image name to <code>devopsclient</code></p>
|
<p>I'm running Apache2 in a docker container and want to write nothing to the disk, writing logs to stdout and stderr. I've seen a few different ways to do this (Supervisord and stdout/stderr, Apache access log to stdout) but these seem like hacks. Is there no way to do this by default?</p>
<p>To be clear, I do not wa... | <p>I'm not positive that this won't mess with httpd's logging at all (e.g. if it tries to seek within the file), but you can set up symlinks from the log paths to /dev/stdout and /dev/stderr, like so:</p>
<pre><code>ln -sf /dev/stdout /path/to/access.log
ln -sf /dev/stderr /path/to/error.log
</code></pre>
<p>The entr... |
<p>I am planning to deploy a production deployment with 'Kubernetes + CoreOS' in Microsoft. And planning to run couple of micro services in the cluster. My plan is to have 5 nodes, I will have 5/6 pods to run each will have 3-5 instances. I was following the official documentation of Kubernetes, I found <a href="https:... | <blockquote>
<p>the deployed VMs are not assigned to Availability Sets</p>
</blockquote>
<p>It is true indeed, as an author and maintainer of the guide, I will welcome a pull-request to enable this, which should be quite easy and probably similar how <a href="https://github.com/kubernetes/kubernetes/blob/7d936fe4cab... |
<p>I started to use Docker and I'm trying out Google's Kubernetes project for my container orchestration. It looks really good!</p>
<p>The only thing I'm curious of is how I would handle the volume storage.</p>
<p>I'm using EC2 instances and the containers do volume from the EC2 filesystem.</p>
<p>The only thing lef... | <p>It's somewhat unclear what you're asking, but a good place to start would be reading about your options for <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md" rel="nofollow"><code>volumes</code> in Kubernetes</a>.</p>
<p>The options include using local EC2 disk with a lif... |
<p>i try to use AWS to setup kubernetes(version 1.0.1) and deploy a few services and pods there.</p>
<p>but i have got stuck with LoadBalancer service. According to the docs i just need to setup correct type of service and open ports in firewall</p>
<p>But service doesn't receive external IP. (ingress is empty)</p>
... | <p>The LoadBalancer should be getting created automatically.</p>
<p>There might be IAM policy issues preventing the load balancer from being created (see <a href="https://github.com/kubernetes/kubernetes/issues/10692" rel="nofollow">Issue #10692</a>).</p>
<p>If that isn't the problem, looking for errors in <code>/var... |
<p>What is the best practice to get Geo distributed cluster with asynchronous network channels ? </p>
<p>I suspect I would need to have some "load balancer" which should redirect connections "within" it's own DC, do you know anything like this already in place?</p>
<p>Second question, should we use one HA cluster or ... | <p>The assumption of the kubernetes development team is that cross-cluster federation will be the best way to handle cross-zone workloads. The tooling for this is easy to imagine, but has not emerged yet. You can (on your own) set up regional or global load-balancers and direct traffic to different clusters based on ... |
<p>I have a Kubernetes cluster running in Amazon EC2 inside its own VPC, and I'm trying to get Dockerized services to connect to an RDS database (which is in a different VPC). I've figured out the peering and routing table entries so I can do this from the minion machines:</p>
<pre><code>ubuntu@minion1:~$ psql -h <... | <p>With the help of Kelsey Hightower, I solved the problem. It turns out it was a Docker routing issue. I've written up the details in a <a href="http://ben.straub.cc/2015/08/19/kubernetes-aws-vpc-peering/" rel="noreferrer">blog post</a>, but the bottom line is to alter the minions' routing table like so:</p>
<pre><co... |
<p>I have been going through this to get started with Kubernetes, running on Mac OS v 10.9.5, Vagrant v 1.7.4, VirtualBox v 4.3.28, and Kubernetes v 1.0.3.:
<a href="https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/vagrant.md">https://github.com/kubernetes/kubernetes/blob/master/docs/get... | <p>The reason is a bug in kubernetes. It <a href="https://github.com/kubernetes/kubernetes/issues/12854" rel="noreferrer">seems to be a TLS error</a>.</p>
<p>If you manually download <a href="https://github.com/kubernetes/kubernetes/releases/tag/v1.0.1" rel="noreferrer">kubernetes 1.0.1</a> you will get closer. Howeve... |
<p>We are currently moving towards microservices with Docker from a monolith application running in JBoss. I want to know the platform/tools/frameworks to be used to test these Docker containers in developer environment. Also what tools should be used to deploy these containers to this developer test environment.</p>
... | <p>I think so. Make sure to get service discovery, logging and virtual networking right. For the former you can check out skydns. Docker now has a few logging plugins you can use for log management. For virtual networking you can look for Flannel and Weave.</p>
<p>You want service discovery because Kubernetes will sch... |
<p>Is there a way to get the status of a deployment? The concept of deployment is modeled somehow? I can't find a "global" info on failures for pods relevant to a particular and I don't know if looking for all the pods makes sense...
As "failure" I mean, for example, if I misspell the docker URL of the image... of cou... | <p>The best way to do this at the moment is using </p>
<pre><code>kubectl describe rc <RC_NAME>
</code></pre>
<p>There's a proposal for implementing a deployment resource to cope with this use case: <a href="https://github.com/kubernetes/kubernetes/blob/55b7500b33553a77f8dceb5404d6af1767399386/docs/proposals/de... |
<p>I have several pods, for example a python web app and a redis(shared by other apps), so I need to place redis in a separate pod. But they are all use the same subnet from docker(172.17.0.0/16) or even the same ip address. how can app pods talk with redis pod?</p>
<p>Maybe what I want ask is what's the best way to s... | <p>How did you set up Kubernetes? I'm not aware of any installation scripts that put pod IPs into a 172 subnet.</p>
<p>But in general, assuming Kubernetes has been set up properly (ideally using one of the provided scripts), using a <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/ser... |
<p>We are running out of disk space for containers running on our nodes. We are running k8s 1.0.1 in aws. We are also trying to do all our configuration in software instead of manually configuring things.
How do we increase the disk size of the nodes? Right now they have 8gb each as created by <a href="https://get.k... | <p>You should be able to do so setting the <code>MINION_ROOT_DISK_SIZE</code> environment variable before creating the cluster. However this option was <a href="https://github.com/kubernetes/kubernetes/pull/11459" rel="nofollow">just merged yesterday</a>, so it may not be available yet unless you use the cluster/kube-u... |
<p>I am trying to setup Kubernetes for the first time. I am following the Fedora Manual installation guide:
<a href="http://kubernetes.io/v1.0/docs/getting-started-guides/fedora/fedora_manual_config.html">http://kubernetes.io/v1.0/docs/getting-started-guides/fedora/fedora_manual_config.html</a></p>
<p>I checked the l... | <p>By default, the kube-apiserver process tries to open a secure (https) server port on port 6443 using credentials from the directory <code>/var/run/kubernetes</code>. If you want to disable the secure port, you can pass <code>--secure-port=0</code> which should make your error go away. Alternatively, you can <a href=... |
<p>As previously reported <a href="https://github.com/kubernetes/kubernetes/issues/11752" rel="nofollow noreferrer">here</a>, <strong>two pods can't mount the same disk even though one of them tries to do it as read-only mode</strong>.</p>
<p>This is supposed to be allowed from Kubernetes documentation.</p>
<h3>Mountin... | <p>According to the <a href="https://cloud.google.com/compute/docs/disks/persistent-disks#use_multi_instances" rel="nofollow">GCE persistent disk documentation</a>: "if you attach a persistent disk to multiple instances, all instances must attach the persistent disk in read-only mode."</p>
<p>The Kubernetes <a href="h... |
<p>I was just wondering how can i point to two env-files, say <code>/var/app/old/file.conf</code> and <code>/var/market/old/db.conf</code> , both in the command line as I find there is support for mutiple -e flags. Does Docker supports pointing to multiple env-file in a command line like the one below</p>
<pre><code>d... | <p>You can do exactly like the command you are running already. For example:</p>
<p>file1</p>
<pre><code>GGG=/home/ppp
</code></pre>
<p>file2</p>
<pre><code>HHH=/ter/ssd
</code></pre>
<p>Then run the Docker command:</p>
<pre><code>docker run -it --env-file=/Users/user/file1 --env-file=/Users/users/file2 centos:6.... |
<p>So my objective here is to set up a cluster of several kafka-brokers in a distributed fashion. But I can't see the way to make the brokers aware of each other.</p>
<p>As far as i understand, every broker needs a separate ID in their config, which I cannot guarantee or configure if I launch the containers from kuber... | <p>My solution for this has been to <strong>use the IP as the ID</strong>: trim the dots and you get a unique ID that is also available outside of the container to other containers.</p>
<p>With a Service you can get access to the multiple containers's IPs (see my answer here on how to do this:
<a href="https://stacko... |
<p>I started a Kubernetes cluster on AWS using:</p>
<pre><code>wget -q -O - https://get.k8s.io | bash
</code></pre>
<p>I then shutdown the cluster. I then tried restarting it and get the following error:</p>
<pre><code>A client error (RouteAlreadyExists) occurred when
calling the CreateRoute operation: The route i... | <p>Looks like the VPC was not correctly deleted. After deleting manually, the installation proceeded as normal.</p>
|
<p>The next version of CloudFoundry / Diego will offer native support for Docker containers which will be orchestrated across multible hosts [<a href="http://thenewstack.io/docker-on-diego-cloud-foundrys-new-elastic-runtime/" rel="noreferrer">link</a>].
This sounds very similar to Kubernetes.</p>
<p>Of course, the pro... | <p>As both a CloudFoundry (past) and Kubernetes (present) commiter, I'm probably uniquely qualified to answer this one.</p>
<h2>PaaS-like</h2>
<p>I like to call CloudFoundry an "Application PaaS" and Kubernetes a "Container PaaS", but the distinction is fairly subtle and fluid, given that both projects change over ti... |
<p>I am following the Fedora getting started guide (<a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/getting-started-guides/fedora/fedora_ansible_config.md">https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/getting-started-guides/fedora/fedora_ansible_config.md</a>) and tryin... | <p>There are several reasons container can fail to start:</p>
<ul>
<li><p>the container command itself fails and exits -> check your docker image and start up script to make sure it works.
Use
<code>sudo docker ps -a</code> to find the offending container and
<code>sudo docker logs <container></code> to check... |
<p>Using Kubernetes for deployment:</p>
<p>Considering I have a Dockerfile, I build, then push to registry.
If I run a container on a host, the image gets pulled and the container is ran.</p>
<p>Now, if i update the Dockerfile, build and push again, <strong>without changing its tag</strong> then the image is changed ... | <p>Set an <code>imagePullPolicy</code> of <code>Always</code> on the container</p>
|
<p>I have several pods, for example a python web app and a redis(shared by other apps), so I need to place redis in a separate pod. But they are all use the same subnet from docker(172.17.0.0/16) or even the same ip address. how can app pods talk with redis pod?</p>
<p>Maybe what I want ask is what's the best way to s... | <p>When you create a service, the service will proxy the connection to the different pods.</p>
<p>A service therefore maintains the list of IPs of the pods' containers.</p>
<p>You can then look those up in the API</p>
<p>they will be at </p>
<pre><code>http(s)://${KUBERNETES_SERVICE_HOST}/api/v1/namespaces/${NAMESP... |
<p>Is there any way to do a rolling-update with a replication controller that has 2 or more containers? </p>
<p>For example, I have Jenkins setup to automatically do a rolling update on a rep controller in our dev environment once a successful build takes place using the --image flag specifying the new container's im... | <p>You are right in saying that <code>kubectl rolling-update frontend --image=image:v2</code> does not give you a way to provide more details about a container when updating a pod that has more than one container. It gives you an error <code>Image update is not supported for multi-container pods</code></p>
<p>But, it ... |
<p>Can someone give an example of how to use the <code>gitRepo</code> type of volume in <strong>Kubernetes</strong>?</p>
<p>The doc says it's a plugin, not sure what that means. Could not find an example anywhere and i don't know the proper syntax.</p>
<p>especially is there parameters to pull a specific branch, use ... | <p><strong>UPDATE</strong>:</p>
<p>gitRepo is now deprecated</p>
<p><a href="https://github.com/kubernetes/kubernetes/issues/60999" rel="nofollow noreferrer">https://github.com/kubernetes/kubernetes/issues/60999</a></p>
<p><strong>ORIGINAL ANSWER</strong>:</p>
<p>going through the code this is what i figured:</p>
... |
<p>So I'm researching how to use Kubernetes for my case. I installed it and played a bit.</p>
<p>The question is when the replication controller starts couple of replicas they have something like an id in their name:</p>
<ol>
<li>How unique is this id? Is it uniqueness for the lifetime of kubernetes? Is it unique acr... | <ol>
<li><p>The ID is guaranteed to be unique at any single point in time, since Kubernetes doesn't allow two pods in the same namespace to have the same name. There aren't any longer-term guarantees though, since they're just <a href="https://github.com/kubernetes/kubernetes/blob/7c9bbef96ed7f2a192a1318aa312919b861aee... |
<p>I know how to run a registry mirror</p>
<pre><code>docker run -p 5000:5000 \
-e STANDALONE=false \
-e MIRROR_SOURCE=https://registry-1.docker.io \
-e MIRROR_SOURCE_INDEX=https://index.docker.io \
registry
</code></pre>
<p>and how to use it </p>
<pre><code>docker --registry-mirror=http://10.0.0.2:5... | <p>You can use a PullSecret to tell Kubernetes what registry to get your containers from. Please see:</p>
<p><a href="http://releases.k8s.io/release-1.0/docs/user-guide/images.md#specifying-imagepullsecrets-on-a-pod" rel="nofollow">http://releases.k8s.io/release-1.0/docs/user-guide/images.md#specifying-imagepullsecret... |
<p>I have a pod that runs containers which require access to sensitive information like API keys and DB passwords. Right now, these sensitive values are embedded in the controller definitions like so:</p>
<pre><code>env:
- name: DB_PASSWORD
value: password
</code></pre>
<p>which are then available inside the Docker... | <p>Unless you have many megabytes of config, this system sounds unnecessarily complex. The intended usage is for you to just put each config into a secret, and the pods needing the config can mount that secret as a volume.</p>
<p>You can then use any of a variety of mechanisms to pass that config to your task, e.g. if... |
<p>Has anyone mounted a private GitHub repository into a kubernetes pod volume?</p>
<p>What is the best way to achieve this?
I thought of two possible ways:</p>
<ol>
<li>Using user / password in HTTPS repository URL</li>
<li>Using private SSH key on the machine</li>
</ol>
<p>I like the second better, but I couldn't ... | <p>GitHub allows cloning repositories using an OAuth token in https URLs as such:</p>
<p><code>$ git clone https://$GH_TOKEN@github.com/owner/repo.git
</code></p>
<p>see
<a href="https://help.github.com/articles/creating-an-access-token-for-command-line-use/" rel="nofollow">https://help.github.com/articles/creating-a... |
<p>I try to <a href="https://cwiki.apache.org/confluence/display/STRATOS/4.1.x+Install+Stratos+with+Kubernetes+in+a+Testing+Environment" rel="nofollow">Install Stratos with Kubernetes in a Testing Environment</a> to build Stratos.I downloading the Kubernetes binaries and provisioned a Docker registry to VAGRANT_KUBERNE... | <p>Did you do a <code>sudo -s</code> on the node ? You have to be an admin to connect to the docker daemon and do queries using docker command line client.</p>
|
<p>I have encountered a scalability problem when trying out the kubernetes cluster. To simplify the topology in my test machine, NodePort type is used to expose the individual service externally. The baremetal to host the node and master is a RHEL 7 with 24 CPUs and 32G RAM; I don't yet have a dedicated load balancer, ... | <p>Hello am kinda new to <a href="https://github.com/kubernetes/kubernetes" rel="nofollow">kubernetes</a> but I have similar questions and concerns. Will try to answer some of them or redirect you to the relevant sections of the user guide.</p>
<p>In case you are deploying Kubernetes on a non cloud enabled providers l... |
<p>I have a containerized app running on a VM. It consists of two docker containers. The first contains the WebSphere Liberty server and the web app. The second contains PostgreSQL and the app's DB.</p>
<p>On my local VM, I just use <strong><em>docker run</em></strong> to start the two containers and then I use <stro... | <p>Yes, you can attach to a container in a pod.
Using Kubernetes 1.0 issue the following command:</p>
<p>Do:</p>
<ul>
<li><code>kubectl get po</code> to get the POD name</li>
<li><code>kubectl describe po POD-NAME</code> to find container name</li>
</ul>
<p>Then:</p>
<p><code>kubectl exec -it POD-NAME -c CONTAINER-... |
<p>Is there a way to pass environment variables through the services in Kubernetes?</p>
<p>I tried passing it in to my service yaml like this:</p>
<pre><code>apiVersion: v1
kind: Service
metadata:
labels:
name: kafka
name: kafka
spec:
ports:
- port: 9092
selector:
name: kafka
env:
- name... | <p>The way that Kubernetes is designed has Services decoupled from Pods. You can not inject a Secret or an env var into a running Pod. What you want is to configure the Pod to use the env var or Secret.</p>
|
<p>What is the recommended way to upgrade a kubernetes cluster as new versions are released?</p>
<p>I heard <a href="https://stackoverflow.com/a/32358515/3045">here</a> it may be <a href="https://github.com/kubernetes/kubernetes/blob/master/cluster/kube-push.sh" rel="nofollow noreferrer">https://github.com/kubernetes/... | <p>The second script you reference (gce/upgrade.sh) only works if your cluster is running on GCE. There isn't (yet) an equivalent script for AWS, but you could look at the script and follow the steps (or write them into a script) to get the same behavior. </p>
<p>The main different between upgrade.sh and kube-push.sh ... |
<p>So I have deployed a Kubernetes cluster and installed a private Docker registry. Here is my registry controller:</p>
<pre><code>---
apiVersion: v1
kind: ReplicationController
metadata:
name: registry-master
labels:
name: registry-master
spec:
replicas: 1
selector:
name: registry-... | <p>if you're using HTTPS, you must have created a self-signed certificate (with your own CA authority) or you have a CA signed certificate.</p>
<p>If so, you need to install this CA cert on the machine you're calling FROM</p>
<p>put your CA cert in </p>
<pre><code>/etc/ssl/certs
</code></pre>
<p>and run </p>
<pre>... |
<p>I'm currently doing some tests on a kubernetes cluster.
I was wondering why the pods aren't rescheduled in some cases :</p>
<ul>
<li>When the node is unreachable</li>
<li>When the remote kubelet doesn't answer</li>
</ul>
<p>Actually the only case when a pod got rescheduled is when the kubelet notify the master.
Is... | <p>There is a quite long default timeout for detecting unreachable nodes and for re-scheduling pods, maybe you did not wait long enough? </p>
<p>You can adjust the timeouts with several flags:</p>
<ul>
<li>node-status-update-frequency on the kubelet (<a href="http://kubernetes.io/v1.0/docs/admin/kubelet.html" rel="no... |
<p>Can someone give an example of how to use the <code>gitRepo</code> type of volume in <strong>Kubernetes</strong>?</p>
<p>The doc says it's a plugin, not sure what that means. Could not find an example anywhere and i don't know the proper syntax.</p>
<p>especially is there parameters to pull a specific branch, use ... | <p>This is a sample application I used:</p>
<pre><code>{
"kind": "ReplicationController",
"apiVersion": "v1",
"metadata": {
"name": "tess.io",
"labels": {
"name": "tess.io"
}
},
"spec": {
"replicas": 3,
"selector": {
"name": "tess.io"
},
"template": {
"metadata":... |
<p>I am using GKE with kubectl installed from gcloud components.
I have created a pv (gcePersistentDisk) with namespace scope using kubectl.</p>
<pre><code>apiVersion: v1
kind: PersistentVolume
metadata:
name: cstor-cs-a-disk-david
namespace: ns-david
spec:
gcePersistentDisk:
pdName: cstor-cs-a-disk-david
... | <p>PVs, like nodes, are not scoped to any namespace. However, as you <a href="https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/#not-all-objects-are-in-a-namespace" rel="noreferrer">noted</a> PVCs, are.</p>
|
<p>I have a working insecure K8S cluster setup: CoreOS alpha image + Vagrant (custom solution follow K8S getting start guide of scratch setup). Now I want to setup the authentication for K8s Cluster Admins who can access API via <code>kubectl cluster-info</code> command etc. I want to setup something similar like <a hr... | <p>I think you may have the exact same issue that I just solved. I believe it was you who asked a similar question on #google-containers and something that user "vishh" said fixed the problem for me. Make sure your master IP/hostname is in the certificate that you use for your api server under the cert's <code>Subject ... |
<p>Cannot get <code>kubectl</code> bash completion to work on Mac. I installed <code>bash-completion</code> with <code>brew</code> i.e. <code>brew install bash-completion</code> then as per the install notes, added it to the <code>~/.bash_profile</code>:</p>
<p><code>if [ -f $(brew --prefix)/etc/bash_completion ]; the... | <p>A patch was provided to fix the issue with bash completion for kubectl. You'll need to use the patch for now if you are on osx until the PR is merged and source the bash completion again, you will also need to install <code>bash-completion</code> as described in the question above.</p>
<p><a href="https://github.co... |
<p>I'm trying to get a ghost blog deployed on GKE, working off of the <a href="https://cloud.google.com/container-engine/docs/tutorials/persistent-disk/" rel="nofollow">persistent disks with WordPress tutorial</a>. I have a working container that runs fine manually on a GKE node:</p>
<pre><code>docker run -d --name my... | <p>If the same docker image is working via <code>kubectl run</code> but not working in a pod, then something is wrong with the pod spec. Compare the full output of the pod as created from spec and as created by rc to see what differs by running <code>kubectl get pods <name> -o yaml</code> for both. Shot in the da... |
<p>Kubernetes volume support is listed here <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md" rel="nofollow">https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md</a> , however it does not currently meet my needs. </p>
<p>I need to support obj... | <p>I have been thinking of ways to enable swift as a volume plugin. Volume plugins for cloud block storage (EBS, cinder, persistent disk) are straight forward when compared to object storage. The main difference being block storage disks can be provisioned and attached to the vm on which kubelet is running, which can b... |
<p>Does Kubernetes download Docker image automatically when i create a pod or should I use Docker pull manually to Download the image locally?</p>
| <p>You do not need to run <code>docker pull</code> manually. The <a href="http://kubernetes.io/v1.0/docs/user-guide/walkthrough/README.html#pod-definition" rel="nofollow">pod definition</a> contains the image name to pull and Kubernetes will pull the image for you. You have several options in terms of defining how Kube... |
<p>I am running a Kubernetes Cluster on Google Container Engine with the default SkyDNS implementation enabled.</p>
<p>How can I add custom DNS Entries in Google Container Engine? Is there any way to:</p>
<ol>
<li>Add custom DNS Entries to SkyDNS that will persist if the SkyDNS container is restarted?</li>
<li>Chang... | <p>At the moment there is not any API to directly manipulate DNS within the cluster. It's something we want to do but have not tackled yet.</p>
<p>Can you explain what you're hoping to achieve?</p>
<p>Edit: if you want to run Consul, nothing is stopping you. Our DNS server is just one implementation.</p>
|
<p>As I know, Google's Kubernetes is based on Google's Borg; however, it seems like Borg is larger than Kubernetes. My understanding is that Borg is a large system containing a sub-system like Kubernetes and its own containers like Docker.</p>
<p>So, I would like to know:</p>
<p>1) In term of containers cluster manag... | <p>I have no 'inside' knowledge of Borg so this answer is based only on what Google themselves have published <a href="http://research.google.com/pubs/pub43438.html">here</a>. For much greater detail, you should look into that paper. Section 8 makes specific reference to Kubernetes and is the basis of this answer (alon... |
<p>I have a kubernetes RC/pod consisting of containers with images like: <code>foobar/my-image:[branch]-latest</code> where "branch" is the git branch ("master", etc).</p>
<p>What's the best way to use rolling-update to force the RC to re-pull the images to get the latest version? The brute force method is to simply d... | <p>You should be able to use a <a href="http://kubernetes.io/v1.0/docs/user-guide/kubectl/kubectl_rolling-update.html" rel="noreferrer">rolling update</a> specifying the same image name that you are currently using:</p>
<pre><code>kubectl rolling-update <replication-controller-name> --image=foobar/myimage:[branc... |
<p>I've the a lot of error logs reported by kubelet :</p>
<pre><code>Sep 07 09:43:51 kubenode-1 kubelet[10320]: I0907 09:43:51.651224 10320 container.go:369] Failed to update stats for container "/docker/01ad0eff434033752c1f39944e9965e38a07081fcbfe26dc35358bb63be18082": failed to read stat from "/sys/class/net/veth2... | <p>If you use Docker v1.7 or above, you may have run into a cadvisor bug, where network stats are not collected correctly. See
<a href="https://github.com/kubernetes/kubernetes/issues/13189" rel="nofollow">https://github.com/kubernetes/kubernetes/issues/13189</a></p>
<p>The bug has already being fixed in cadvisor, and... |
<p>I'm searching for a main difference between OpenShift V3 and V2.
Is OpenShift V2 working like this?: <a href="https://www.openshift.com/walkthrough/how-it-works" rel="nofollow">https://www.openshift.com/walkthrough/how-it-works</a>
And how are Docker and Kubernetes working in V3?</p>
<p>Can someone give me a clear ... | <p>This is a rather broadly asked question, so I will (and can) answer only in a rather broad manner.</p>
<p>There are a lot of key concepts that have changed. These are the most important ones and you'll need some time to get into it, but they are a big improvement to OpenShift v2.:</p>
<ul>
<li>Cartridges vs. Docke... |
<p>Do sporadic disk cleanup operations happen automatically in Kubernetes or should this be a scheduled "docker RM/RMI" to remove discarded images? A single node in my dev K8s cluster (other nodes are fine) keeps running out of disk space in / and the following message is show in the K8s UI events:</p>
<p>reason: fre... | <p>Yes,Kubernetes supports container and image garbage collection. More details in <a href="https://kubernetes.io/docs/concepts/cluster-administration/kubelet-garbage-collection/" rel="nofollow noreferrer">https://kubernetes.io/docs/concepts/cluster-administration/kubelet-garbage-collection/</a></p>
<p>You may want to... |
<p>On GKE, <strong>kube-dns</strong> is running on my nodes, I can see the docker containers.</p>
<p>I do have access to <strong>Services</strong> by name, which is great for all these applications where load balancing is a perfectly suitable solution, but <em>how would I use the DNS to access individual pods?</em> </... | <p><strong>UPDATE</strong></p>
<p>According to the docs, the format is now:</p>
<p><code>_my-port-name._my-port-protocol.my-svc.my-namespace.svc.cluster.local</code></p>
<p>See the related doc here:
<a href="https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pods" rel="noreferrer">https://kuber... |
<p>How can I find out if a given Docker image can be run using Kubernetes? </p>
<p>What should I do to help ensure that my images will run well in any Kubernetes-managed environment?</p>
| <p>All Docker images can be run on Kubernetes -- it uses Docker to run the images.</p>
<p>You can expose ports from containers just like when using Docker directly, pass in environment variables, mount storage volumes from the host into the container, and more.</p>
<p>If you have anything particular in mind, I'd be i... |
<p>Is it possible to specify a <a href="http://kubernetes.io/v1.0/docs/user-guide/labels.html#set-based-requirement" rel="nofollow">set-based label selector</a> for a replication controller? I cannot figure out the syntax to do so in the request json. I can't find anything in the documentation, so if you have a link to... | <p>This is something we want to support, and is/was underway (see PR 7053), but it is not yet possible. </p>
<p>You can observe the status/progress on:
<a href="https://github.com/kubernetes/kubernetes/issues/341" rel="nofollow">https://github.com/kubernetes/kubernetes/issues/341</a></p>
<p>It's possible to work arou... |
<p>After running Kubernetes on AWS for a few days, my master node goes dead. This has happened after setting up 2 different clusters. The pods are still running and available, but there's no way to manage / proxy.</p>
<p>Question is why? Or alternatively, how do I replace the master node on AWS? Or alternatively, ... | <p>It's almost certainly that the initial size of machine was too low, and ran out of memory (or something similar). To use a larger cluster size, follow this link[1] and set an environment variable before you bring up your cluster.</p>
<p>In this case, something like:</p>
<pre><code>export MINION_SIZE=t2.large
</cod... |
<p>I'm having quite a bit of fun with the gcePersistentDisk in the context of pods inside of kubernetes:</p>
<p>Currently I'm attempting to get my rethinkdb cluster to work well with a gcePersistentDisk mounted volume in order to facilitate backups, data recovery, data integrity, etc. This is proving a bit more diffic... | <p>Unfortunately I don't know anything about rethinkdb, but it's very reasonable to use a gcePersistentDisk to store the data. That way if the Kubernetes node running your pod dies, the pod can be restarted on another node (assuming you have more than one node in your Kubernetes cluster) and continue to access the data... |
<p>I have a kubernetes cluster running on coreos. I wish to run journal2gelf <a href="https://github.com/systemd/journal2gelf" rel="noreferrer">https://github.com/systemd/journal2gelf</a> in a container in a pod I call logging. (I also have a fluentd container in this pod, which works great, I highly recommend it for... | <p>This will let you send stdin to a container:</p>
<p><code>kubectl exec -i POD_NAME COMMAND</code></p>
<p>Or</p>
<p><code>kubectl attach -i POD_NAME</code></p>
<p>But there isn't a good way to define to stdin sent to all containers in a pod, or all containers spawned by a replication controller</p>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.