input stringclasses 1
value | output stringlengths 30 28.3k | text stringlengths 151 31.8k | instruction stringlengths 49 30.3k |
|---|---|---|---|
Run kubectl config view. It'll dump out the auth information used to access your cluster, including the basic auth username and password.
| ###Instruction: 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.
### Response: Run kubectl config view. It'll dump out the auth information used to access your cluster,... | 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.
| |
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.
However, I don't believe we actually know how bad it is. A team member briefly tried testing it ear... | ###Instruction: Some time ago I asked about handling thousands of services in a Kubernetes cluster:
Can Kubernetes handle thousands of services?
At that time Kubernetes was using env vars and my question was more oriented to that. Now that Kubernetes has a DNS sounds like we don't have the problem with env vars anymore... | Some time ago I asked about handling thousands of services in a Kubernetes cluster:
Can Kubernetes handle thousands of services?
At that time Kubernetes was using env vars and my question was more oriented to that. Now that Kubernetes has a DNS sounds like we don't have the problem with env vars anymore, however the do... | |
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.
"Level based" components are more resilient ... | ###Instruction: What does "level-based" and "edge-based" mean in general?
I read "In other words, the system's behavior is level-based rather than edge-based" from kubernetes documentation:
https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api-conventions.md
with Google, I only find:
http://www.keil.c... | What does "level-based" and "edge-based" mean in general?
I read "In other words, the system's behavior is level-based rather than edge-based" from kubernetes documentation:
https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/api-conventions.md
with Google, I only find:
http://www.keil.com/forum/9423/ed... | |
The --update-period 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 --update-period to be at least as long as it takes ea... | ###Instruction: I'm using Google Container Engine with a cluster using Kubernetes 0.20.2.
In this cluster, I have 1 replication controller (2 replicas) and 1 service with a spec type defined to LoadBalancer (basic setup).
Everything is working fine here;
Then I want to roll update to a different image using the kubectl... | I'm using Google Container Engine with a cluster using Kubernetes 0.20.2.
In this cluster, I have 1 replication controller (2 replicas) and 1 service with a spec type defined to LoadBalancer (basic setup).
Everything is working fine here;
Then I want to roll update to a different image using the kubectl command:
kubect... | |
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.
In the mean time, you can manually create a secret for the DNS service that contains a ku... | ###Instruction: I've just installed a kubernetes testinstallation directly on my fedora laptop using this guide.
After starting kube2sky I've noticed I can't connect to the kubernetes api since the certificates are required. kubernetes-ro is deprecated and no longer available on my machine, so I get the following error... | I've just installed a kubernetes testinstallation directly on my fedora laptop using this guide.
After starting kube2sky I've noticed I can't connect to the kubernetes api since the certificates are required. kubernetes-ro is deprecated and no longer available on my machine, so I get the following errors:
E0627 15:58:0... | |
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.
If you need to deploy them together (e.g. they share local disk o... | ###Instruction: 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?
And if they are in the same pod, does this have any implications in terms of the maximum size of applicatio... | 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?
And if they are in the same pod, does this have any implications in terms of the maximum size of application that can be ru... | |
Our target is 5s latency from creation -> Running (assuming image is pre-pulled). The issue tracking this was https://github.com/GoogleCloudPlatform/kubernetes/issues/3954.
This issue was closed a couple weeks ago, so please update to version 20.2 and give it another try.
| ###Instruction: 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).
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... | 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).
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 cached (I presu... | |
My previous answer was incorrect, edited with correct info
The -h flag for docker run will set the hostname of the container when you create it.
Test it out: docker run -h test.example.com -it ubuntu /bin/bash
The docker start command does not have the same -h or --hostname argument though. It doesn't seem possible to ... | ###Instruction: I want to set the hostname in a container running inside Kubernetes, but Kubernetes appears to be overriding whatever I set at runtime.
I've tried both setting /etc/hostname in the docker image I'm having Kubernetes use, and including echo "host.example.com > /etc/hostname" in the CMD in the Dockerfile.... | I want to set the hostname in a container running inside Kubernetes, but Kubernetes appears to be overriding whatever I set at runtime.
I've tried both setting /etc/hostname in the docker image I'm having Kubernetes use, and including echo "host.example.com > /etc/hostname" in the CMD in the Dockerfile.
There appears t... | |
Because flannel is not working properly so do
/root/kube/reconfDocker.sh on everynode
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.
| ###Instruction: 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
Cluster details:
172.16.2.92 -- master and minion
172.16.2.91 -- minion
RC and service detail... | 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
Cluster details:
172.16.2.92 -- master and minion
172.16.2.91 -- minion
RC and service details:
frontend-cont... | |
The PublicIP thing is changing lately and I don't know exactly where it landed. But, services are the 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, from another ... | ###Instruction: 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).
Each pod contains the webapp (which is stateless) and I run any number of pods via replication c... | 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).
Each pod contains the webapp (which is stateless) and I run any number of pods via replication controllers.
I se... | |
See the Compute Resources 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.
As you scale up the number of pods you are running, the scheduler will attempt to place them in the available space. If there is no way... | ###Instruction: A few kubernetes novice questions.
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.
There its a way I can cho... | A few kubernetes novice questions.
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.
There its a way I can choose the amount o... | |
Run
gcloud container clusters get-credentials my-cluster-name
to update the kubeconfig file and point kubectl at a cluster on Google Container Engine.
| ###Instruction: I have followed the installation steps:
https://cloud.google.com/container-engine/docs/tutorials/guestbook#install_gcloud_and_kubectl
A Google Container Engine cluster is up and running and gcloud CLI is authenticated and works.
But kubectl says:
"couldn't read version from server: Get http://local... | I have followed the installation steps:
https://cloud.google.com/container-engine/docs/tutorials/guestbook#install_gcloud_and_kubectl
A Google Container Engine cluster is up and running and gcloud CLI is authenticated and works.
But kubectl says:
"couldn't read version from server: Get http://local host:8080/api: ... | |
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:.
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 cloud provi... | ###Instruction: Assume the following stack:
A dedicated server
The server is running Vagrant
Vagrant is running 2 virtual machines master + minion-1 (Kubernetes)
minion-1 is running a pod
Within the pod is 2 containers: webservice and fileservice
Both webservice and fileservice should be accessible from internet i.e.... | Assume the following stack:
A dedicated server
The server is running Vagrant
Vagrant is running 2 virtual machines master + minion-1 (Kubernetes)
minion-1 is running a pod
Within the pod is 2 containers: webservice and fileservice
Both webservice and fileservice should be accessible from internet i.e. from outside. E... | |
It looks like issue is gone, I've tried one more time and installation went flawlessly:
| ###Instruction: When I run the Kubernetes vagrant setup script:
export KUBERNETES_PROVIDER=vagrant
curl -sS https://get.k8s.io | bash
I get:
Validating master
Validating minion-1
Waiting for each minion to be registered with cloud provider
error: couldn't read version from server: Get https://10.245.1.2/api:dial tcp ... | When I run the Kubernetes vagrant setup script:
export KUBERNETES_PROVIDER=vagrant
curl -sS https://get.k8s.io | bash
I get:
Validating master
Validating minion-1
Waiting for each minion to be registered with cloud provider
error: couldn't read version from server: Get https://10.245.1.2/api:dial tcp 10.245.1.2:443: ... | |
Update (May 2016): As of late March 2016, gcloud will now install kubectl for windows.
gcloud won't currently install kubectl on windows (hence the error). You can download a recent kubectl binary directly from GCS instead (gsutil cp gs://kubernetes-release/release/v1.0.0/bin/windows/amd64/kubectl.exe kubectl.exe).
... | ###Instruction: I'm trying to spin up a Kubernetes (k8s) cluster on GCE. When I run
gcloud components update kubectl
on a Windows machine I get
ERROR: (gcloud.components.update) The following components are unknown [kubectl]
### Response: Update (May 2016): As of late March 2016, gcloud will now install kubectl for... | I'm trying to spin up a Kubernetes (k8s) cluster on GCE. When I run
gcloud components update kubectl
on a Windows machine I get
ERROR: (gcloud.components.update) The following components are unknown [kubectl]
| |
The recommended way to install the Cloud SDK non-interactively is to set the environment variable CLOUDSDK_CORE_DISABLE_PROMPTS:
export CLOUDSDK_CORE_DISABLE_PROMPTS=1
This will make the Cloud SDK run in non-interactive mode, in which it accepts the default value for all prompts. This applies both to installation and ... | ###Instruction: 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 circle.yml file with dependencies like this:
dependencies:
cache_directories:
- ~/kubernetes
- ./google-cloud-sdk
pre:
- chmod a+x ./download-gc... | 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 circle.yml file with dependencies like this:
dependencies:
cache_directories:
- ~/kubernetes
- ./google-cloud-sdk
pre:
- chmod a+x ./download-gcloud.sh ./instal... | |
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:
--patch='{ metadata:{ "apiVersion":"v1" }, "spec": { "selector": { "build":"2"} } }'
| ###Instruction: I'm trying to update a service using :
kubectl update service my-service \
--patch='{ "apiVersion":"v1", "spec": { "selector": { "build":"2"} } }'
I receive the following Error :
Error from server: service "\"apiVersion\":\"v1\"," not found
I have tried the following :
moving the service name to t... | I'm trying to update a service using :
kubectl update service my-service \
--patch='{ "apiVersion":"v1", "spec": { "selector": { "build":"2"} } }'
I receive the following Error :
Error from server: service "\"apiVersion\":\"v1\"," not found
I have tried the following :
moving the service name to the end
Removing ... | |
By default, the master only exposes HTTPS to the public internet, not HTTP. You should be able to hit https://admin:password@master-public-ip/api/v1/pods/, where password is the generated password for the admin user. This can be found either in the .kube/config file on your machine, or in the /srv/kubernetes/known_toke... | ###Instruction: I can get Pods information using http://localhost:8001/api/v1/pods from inside my cluster.
Is there any way to get pod informations using http://master-public-ip:8001/api/v1/pods ?
### Response: By default, the master only exposes HTTPS to the public internet, not HTTP. You should be able to hit https:... | I can get Pods information using http://localhost:8001/api/v1/pods from inside my cluster.
Is there any way to get pod informations using http://master-public-ip:8001/api/v1/pods ?
| |
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.
The --tls-cert-file and --tls-private-key-file arguments for the kubelet are used to configure the http server on the kubelet (if not specified,... | ###Instruction: I deployed apiserver on master node (core01) with following conf:
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.0.0/16... | I deployed apiserver on master node (core01) with following conf:
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.0.0/16 \
--allow_pri... | |
You can definitely use kubectl without gcloud. You can download the latest official Kubernetes release from its releases page on Github, then run kubectl by untarring it and either running ./cluster/kubectl.sh or copying the kubectl binary from platforms/$OS/$ARCHITECTURE/kubectl into your shell's path.
Also, setting u... | ###Instruction: As per this question, I was wondering if there are any plans to be able to use the kubectl tool without installing gcloud?
The use case I have in mind is the same as the one that fellow had: running kubernetes on CoreOS locally via vagrant.
### Response: You can definitely use kubectl without gcloud. Y... | As per this question, I was wondering if there are any plans to be able to use the kubectl tool without installing gcloud?
The use case I have in mind is the same as the one that fellow had: running kubernetes on CoreOS locally via vagrant.
| |
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.
If you run something as a pod rather than as a replication controller, you can set the restartPolicy field on it. The OnFailure policy is probably what you'd ... | ###Instruction: 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.
Is there a way now to let pods die? Or maybe other workaround... | 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.
Is there a way now to let pods die? Or maybe other workarounds to do pods gar... | |
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.
Unfortunately, a new GCE persistence disk contains a lost+found directory.
I've submitted a fix for the docker image here.
| ###Instruction: 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: http://amygdala.github.io/kubernetes/2015/01/13/k8s1.html
However, when I try to... | 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: http://amygdala.github.io/kubernetes/2015/01/13/k8s1.html
However, when I try to achieve a simil... | |
If you just want to kick the tires with Kubernetes, I'd recommend installing boot2docker and then following the Running kubernetes locally via Docker getting started guide. Once you are comfortable interacting with the Kubernetes API and want a more complex local setup, you can then work on installing Vagrant.
If the ... | ###Instruction: 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 https://github.com/Googl... | 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 https://github.com/GoogleCloudPlatform/k... | |
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.
I suspect you created your service in step 3 with type: LoadBalancer. This won't work properly because of h... | ###Instruction: 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.
However, when I try and set up a HTTP load balancer, the health checks always say that the instances are u... | 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.
However, when I try and set up a HTTP load balancer, the health checks always say that the instances are unhealthy (even t... | |
Your pod spec file looks like invalid.
According to http://kubernetes.io/v1.0/docs/user-guide/walkthrough/README.html#multiple-containers, a valid multiple containers pod spec should like this
apiVersion: v1
kind: Pod
metadata:
name: www
spec:
containers:
- name: nginx
image: nginx
volumeMounts:
- mou... | ###Instruction: I would like to create a kubernetes pod that contains 2 containers, both with different images, so I can start both containers together.
Currently I have tried the following configuration:
{
"id": "podId",
"desiredState": {
"manifest": {
"version": "v1beta1",
"id": "podId",
"co... | I would like to create a kubernetes pod that contains 2 containers, both with different images, so I can start both containers together.
Currently I have tried the following configuration:
{
"id": "podId",
"desiredState": {
"manifest": {
"version": "v1beta1",
"id": "podId",
"containers": [{
... | |
I don't yet know the fix but I know what is going wrong since it happens to me as well:
OS X 10.10.3
Vagrant 1.7.4
VirtualBox 4.3.30
Kubernetes 1.0.1
When I run the default configuration of this (which creates one "master" and one "minion" VM) I see that the static IP address is not being assigned to the "eth1" inter... | ###Instruction: 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 https://github.com/Googl... | 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 https://github.com/GoogleCloudPlatform/k... | |
It's worth noting that you can now do both Autoscaling and Resize a running Google Container Engine Cluster by using Instance Groups - https://cloud.google.com/compute/docs/instance-groups/
| ###Instruction: 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.
I saw the StackOverflow questions:
Autoscaling in Google Container Engine
Increasing the cluster size in Google Container Engine
And I unders... | 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.
I saw the StackOverflow questions:
Autoscaling in Google Container Engine
Increasing the cluster size in Google Container Engine
And I understood that the au... | |
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:
"resources": {
"limits": {
"cpu": "490m"
}
}
I have no idea how and why this particular value influences ... | ###Instruction: 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 N nodes/minions, and have... | 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 N nodes/minions, and have M jobs to compu... | |
tl;dr gcloud container get-credentials --cluster=CLUSTER_ID --zone=YOURZONE
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 tell it to install the component.
If you're get... | ###Instruction: I am getting the following error when trying to run kubectl locally.
error: couldn't read version from server: Get http://localhost:8080/api: dial tcp 127.0.0.1:8080: connection refused
I know this relates to the kubectl config but I'm at a loss in how to resolve it. 2 days ago, I was experimenting wit... | I am getting the following error when trying to run kubectl locally.
error: couldn't read version from server: Get http://localhost:8080/api: dial tcp 127.0.0.1:8080: connection refused
I know this relates to the kubectl config but I'm at a loss in how to resolve it. 2 days ago, I was experimenting with GKE and did se... | |
The containers in same pod shares the localhost, so you need not link containers, just use localhost:containerPort.
| ###Instruction: 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.
Does anybody tried linking containers using Kubernetes config.
### Response: The containers in same pod shares the localhost, so you... | 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.
Does anybody tried linking containers using Kubernetes config.
| |
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 hostPort in the ports section of its containers spec.
However, I can't say I'm completely sure why you wo... | ###Instruction: 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 N nodes/minions, and have... | 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 N nodes/minions, and have M jobs to compu... | |
You should use a readiness check (http://kubernetes.io/v1.0/docs/user-guide/production-pods.html#liveness-and-readiness-probes-aka-health-checks)
that transitions the Pod to "not ready" after you receive a SIGTERM
Once that happens, the service will remove the Pod from serving, prior to the delete.
(without a readine... | ###Instruction: 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:
package main
import (
"fmt"
"io"
"net/http"
"os"
"os/signal"
"syscall"
"github.com/braintree/manners"
)
fu... | 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:
package main
import (
"fmt"
"io"
"net/http"
"os"
"os/signal"
"syscall"
"github.com/braintree/manners"
)
func main() {
... | |
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 VMware, KVM/QEMU, and other cloud/IaaS providers like DigitalOcean. It was developed by Hashicorp but it's open source.
Dockramp i... | ###Instruction: Can someone please explain the advantages/disadvantages using the following when building container images, rather than using the dockerfile.
Packer - tool for creating machine and container images for multiple platforms from a single source configuration
Dockramp - A Client-driven Docker Container Im... | Can someone please explain the advantages/disadvantages using the following when building container images, rather than using the dockerfile.
Packer - tool for creating machine and container images for multiple platforms from a single source configuration
Dockramp - A Client-driven Docker Container Image Builder
| |
I recently stumbled upon the same issue. Have a look at BLOCK_DEVICE_MAPPINGS in kubernetes/cluster/aws/util.sh. You can modify it to have something more appropriate for a EBS-only minion.
For example:
[{"DeviceName":"/dev/sda1","Ebs":{"VolumeSize":80}}]
AWS docs: http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/bl... | ###Instruction: I successfully deployed Kubernetes on AWS using "getting started on AWS ec2 guide" (http://kubernetes.io/v1.0/docs/getting-started-guides/aws.html), but the disk size of all the minions (kubernetes hosts) is 8gb. I would like to increase the disk size, but I haven't found a way to do it.
I can change t... | I successfully deployed Kubernetes on AWS using "getting started on AWS ec2 guide" (http://kubernetes.io/v1.0/docs/getting-started-guides/aws.html), but the disk size of all the minions (kubernetes hosts) is 8gb. I would like to increase the disk size, but I haven't found a way to do it.
I can change the VM size by se... | |
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.
However, the fabric8 folks have put together a console that does allow you to change what's r... | ###Instruction: 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.
But what is the approach if we need to modify some properties of Kubernetes cluster (... | 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.
But what is the approach if we need to modify some properties of Kubernetes cluster (like increasing ... | |
If there isn't a Heapster pod running in your cluster, then your cluster was created before we started enabling cluster monitoring by default.
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 cluster (laun... | ###Instruction: I am running a Kubernetes cluster on Google container engine. My metrics are not getting pushed to Stackdriver by default.
Do I need to start Heapster service explicitly or is it automatically managed by container engine itself?
### Response: If there isn't a Heapster pod running in your cluster, then ... | I am running a Kubernetes cluster on Google container engine. My metrics are not getting pushed to Stackdriver by default.
Do I need to start Heapster service explicitly or is it automatically managed by container engine itself?
| |
There is a patch out for review at the moment (#12384) 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 option in the next couple of days. In the meantime, you can see from the patch how easy it i... | ###Instruction: 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.... | 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 want t... | |
In your service definition, set its type field to LoadBalancer, and kubernetes will automatically create an AWS Elastic Load Balancer for you if you're running on AWS. This feature should work on GCE/GKE, AWS, and OpenStack.
For an example, check out the guestbook-go example.
| ###Instruction: Kubernetes create a load balancer, for each service; automatically in GCE. How can I manage something similar on AWS?
Kubernetes service basically use the kubeproxy to handle the internal traffic. But that kubeproxy ip its do not have access to the external network.
There its a way to accomplish this?
... | Kubernetes create a load balancer, for each service; automatically in GCE. How can I manage something similar on AWS?
Kubernetes service basically use the kubeproxy to handle the internal traffic. But that kubeproxy ip its do not have access to the external network.
There its a way to accomplish this?
| |
The probe frequency is controlled by the sync-frequency command line flag on the Kubelet, which defaults to syncing pod statuses once every 10 seconds.
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.
If either of these features is important... | ###Instruction: Is probe frequency customizable in liveness/readiness probe?
Also, how many times readiness probe fails before it removes the pod from service load-balancer? Is it customizable?
### Response: The probe frequency is controlled by the sync-frequency command line flag on the Kubelet, which defaults to syn... | Is probe frequency customizable in liveness/readiness probe?
Also, how many times readiness probe fails before it removes the pod from service load-balancer? Is it customizable?
| |
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 app.google.stackdriver.com/gke
| ###Instruction: A newly created Kubernetes cluster on GKE is not pushing its metrics to Stackdriver. Output of kubectl cluster-info is:
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 running at https:/... | A newly created Kubernetes cluster on GKE is not pushing its metrics to Stackdriver. Output of kubectl cluster-info is:
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 running at https://XXX.XXX.XXX.XXX... | |
Only one secret is allowed per secret volume
| ###Instruction: I'm trying to mount several secrets in the same secret-volume for a kubernetes pod blueprint, but it's not accepted.
Tried and can't be created :
"spec": {
"volumes": [
{
"name": "secret-volume",
"secret": [
{ "secretName": "secret1" },
... | I'm trying to mount several secrets in the same secret-volume for a kubernetes pod blueprint, but it's not accepted.
Tried and can't be created :
"spec": {
"volumes": [
{
"name": "secret-volume",
"secret": [
{ "secretName": "secret1" },
... | |
I can think of a couple of ways to access services across multiple clusters connected to the same GCP private network:
Bastion route into k2 for all of k2's services:
Find the SERVICE_CLUSTER_IP_RANGE for the k2 cluster. On GKE, it will be the servicesIpv4Cidr field in the output of cluster describe:
$ gcloud beta con... | ###Instruction: 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.
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 a... | 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.
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 would have t... | |
The ServiceAccount admission controller prevents pods from being created until their service account in their namespace is initialized.
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 for that se... | ###Instruction: I followed the official Kubernetes installation guide to install Kubernetes on Fedora 22 severs. Everything works out for me during the installation .
After the installation. I could see all my nodes are up-running and connected to the master. However, it kept failing while I try to create a simple pod,... | I followed the official Kubernetes installation guide to install Kubernetes on Fedora 22 severs. Everything works out for me during the installation .
After the installation. I could see all my nodes are up-running and connected to the master. However, it kept failing while I try to create a simple pod, according to th... | |
After manually removing the Forwarding Rules Under "Networking->Load Balancing->Network Load Balancing" (Or you can use gcloud compute forwarding-rules delete) 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 Kubectl stop servic... | ###Instruction: I ran into some trouble getting an external ip address after posting the following json object (variables excluded):
$json= '{
"kind": "Service",
"apiVersion": "v1",
"metadata": {
"name": ""
},
"spec": {
"ports": [{
... | I ran into some trouble getting an external ip address after posting the following json object (variables excluded):
$json= '{
"kind": "Service",
"apiVersion": "v1",
"metadata": {
"name": ""
},
"spec": {
"ports": [{
"port": 80,
... | |
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.
This means that you can't use signal to signal other processes in the Pod.
You can, however, use IPC mechanisms like pipes and shared mem... | ###Instruction: On this page in the Kubernetes docs Pods, it states
The context of the pod can be defined as the conjunction of several Linux namespaces:
PID namespace (applications within the pod can see each other's processes)
network namespace (applications within the pod have access to the same IP and port space... | On this page in the Kubernetes docs Pods, it states
The context of the pod can be defined as the conjunction of several Linux namespaces:
PID namespace (applications within the pod can see each other's processes)
network namespace (applications within the pod have access to the same IP and port space)
IPC namespace ... | |
A common misconception is that a Pod should manage a vertical, multi-tier stack: for example a web tier + DB tier together.
It's interesting to read the Kubernetes design intent of Pods: they're for collecting 'helper' processes rather than composing a vertical stack.
To answer your questions, I'd recommend:
Define a ... | ###Instruction: 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 acce... | 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 lo... | |
The issue was on the volume definition, the hostPath.path property should hold the absolute address of the directory to mount.
Example:
hostPath:
path: /home/bitgandtter/Documents/development/php/k8s_devel_env
| ###Instruction: I want to use kubernetes as my default development environment for that I set up the cluster locally with docker as explained in the official doc. I push my example to a github repository
My set up steps after having a kubernetes cluster running were:
* cd cluster_config/app && docker build --tag=k8s_ph... | I want to use kubernetes as my default development environment for that I set up the cluster locally with docker as explained in the official doc. I push my example to a github repository
My set up steps after having a kubernetes cluster running were:
* cd cluster_config/app && docker build --tag=k8s_php_dev . && cd ..... | |
So this regular expression: [a-z0-9]+(?:[._-][a-z0-9]+)* doesn't include any upper case letters. So you should change your image name to devopsclient
| ###Instruction: I am trying to build my image using this plugin: https://github.com/spotify/docker-maven-plugin#use-a-dockerfile
When I run mvn clean package docker:build
I get this error:
[ERROR] Failed to execute goal com.spotify:docker-maven-plugin:0.2.3:build (defa
ult-cli) on project demo: Exception caught: Reques... | I am trying to build my image using this plugin: https://github.com/spotify/docker-maven-plugin#use-a-dockerfile
When I run mvn clean package docker:build
I get this error:
[ERROR] Failed to execute goal com.spotify:docker-maven-plugin:0.2.3:build (defa
ult-cli) on project demo: Exception caught: Request error: POST ht... | |
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:
ln -sf /dev/stdout /path/to/access.log
ln -sf /dev/stderr /path/to/error.log
The entry command to the vanilla httpd conta... | ###Instruction: 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?
To be clear, I do n... | 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?
To be clear, I do not want to tail ... | |
the deployed VMs are not assigned to Availability Sets
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 affinity groups are currently handled.
Not able to specify an existing Virtual Network, Resources, loca... | ###Instruction: 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 ht... | 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 https://github.com... | |
It's somewhat unclear what you're asking, but a good place to start would be reading about your options for volumes in Kubernetes.
The options include using local EC2 disk with a lifetime tied to the lifetime of your pod (emptyDir), local EC2 disk with lifetime tied to the lifetime of the node VM (hostDir), and an Elas... | ###Instruction: I started to use Docker and I'm trying out Google's Kubernetes project for my container orchestration. It looks really good!
The only thing I'm curious of is how I would handle the volume storage.
I'm using EC2 instances and the containers do volume from the EC2 filesystem.
The only thing left is the wa... | I started to use Docker and I'm trying out Google's Kubernetes project for my container orchestration. It looks really good!
The only thing I'm curious of is how I would handle the volume storage.
I'm using EC2 instances and the containers do volume from the EC2 filesystem.
The only thing left is the way I have to depl... | |
The LoadBalancer should be getting created automatically.
There might be IAM policy issues preventing the load balancer from being created (see Issue #10692).
If that isn't the problem, looking for errors in /var/log/kube-controller-manager.log on the master VM may give you an idea of what is going wrong.
| ###Instruction: i try to use AWS to setup kubernetes(version 1.0.1) and deploy a few services and pods there.
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
But service doesn't receive external IP. (ingress is empty)
Do i nee... | i try to use AWS to setup kubernetes(version 1.0.1) and deploy a few services and pods there.
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
But service doesn't receive external IP. (ingress is empty)
Do i need to create Load... | |
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 thi... | ###Instruction: What is the best practice to get Geo distributed cluster with asynchronous network channels ?
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?
Second question, should we use one HA cluster or cre... | What is the best practice to get Geo distributed cluster with asynchronous network channels ?
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?
Second question, should we use one HA cluster or create dedicated cl... | |
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 blog post, but the bottom line is to alter the minions' routing table like so:
$ sudo iptables -t nat -I POSTROUTING -d <RDS-IP-ADDRESS>/32 -o eth0 -j MASQUERADE
| ###Instruction: 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:
ubuntu@minion1:~$ psql -h <rds-in... | 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:
ubuntu@minion1:~$ psql -h <rds-instance-name>
Pas... | |
The reason is a bug in kubernetes. It seems to be a TLS error.
If you manually download kubernetes 1.0.1 you will get closer. However, there's been a bugfix that you'll need to patch into 1.0.1 to make it work properly with vagrant. Otherwise, network provisioning will not work and you'll run into this issue.
So, as s... | ###Instruction: 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.:
https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/vagrant.md
Full install log can be found here:
http://mcdonaldland.in... | 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.:
https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/vagrant.md
Full install log can be found here:
http://mcdonaldland.info/files/kuberne... | |
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.
You want service discovery because Kubernetes will schedule the c... | ###Instruction: 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 envir... | 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.
Is it a ... | |
The best way to do this at the moment is using
kubectl describe rc <RC_NAME>
There's a proposal for implementing a deployment resource to cope with this use case: https://github.com/kubernetes/kubernetes/blob/55b7500b33553a77f8dceb5404d6af1767399386/docs/proposals/deployment.md
| ###Instruction: 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 im... | 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 course... | |
How did you set up Kubernetes? I'm not aware of any installation scripts that put pod IPs into a 172 subnet.
But in general, assuming Kubernetes has been set up properly (ideally using one of the provided scripts), using a service object to load balance across your 1 or more redis pods would be the standard approach.
| ###Instruction: 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?
Maybe what I want ask is what's the best way... | 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?
Maybe what I want ask is what's the best way to setup multi-... | |
You should be able to do so setting the MINION_ROOT_DISK_SIZE environment variable before creating the cluster. However this option was just merged yesterday, so it may not be available yet unless you use the cluster/kube-up.sh script from HEAD of the repository.
| ###Instruction: 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 https://g... | 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 https://get.k8s.io | bash... | |
By default, the kube-apiserver process tries to open a secure (https) server port on port 6443 using credentials from the directory /var/run/kubernetes. If you want to disable the secure port, you can pass --secure-port=0 which should make your error go away. Alternatively, you can manually create certificates for your... | ###Instruction: I am trying to setup Kubernetes for the first time. I am following the Fedora Manual installation guide:
http://kubernetes.io/v1.0/docs/getting-started-guides/fedora/fedora_manual_config.html
I checked the logs of my API server and am getting this error:
server.go:464] Unable to listen for secure (ope... | I am trying to setup Kubernetes for the first time. I am following the Fedora Manual installation guide:
http://kubernetes.io/v1.0/docs/getting-started-guides/fedora/fedora_manual_config.html
I checked the logs of my API server and am getting this error:
server.go:464] Unable to listen for secure (open /var/run/kuber... | |
According to the GCE persistent disk documentation: "if you attach a persistent disk to multiple instances, all instances must attach the persistent disk in read-only mode."
The Kubernetes documentation for GCE PD volumes also explains this limitation: "A feature of PD is that they can be mounted as read-only by multip... | ###Instruction: As previously reported here, two pods can't mount the same disk even though one of them tries to do it as read-only mode.
This is supposed to be allowed from Kubernetes documentation.
Mounting scheme is:
UniqueCluster/PodA has successfully mounted gdeDisk1 as read-write
UniqueCluster/PodB fails to star... | As previously reported here, two pods can't mount the same disk even though one of them tries to do it as read-only mode.
This is supposed to be allowed from Kubernetes documentation.
Mounting scheme is:
UniqueCluster/PodA has successfully mounted gdeDisk1 as read-write
UniqueCluster/PodB fails to start when mounting ... | |
You can do exactly like the command you are running already. For example:
file1
GGG=/home/ppp
file2
HHH=/ter/ssd
Then run the Docker command:
docker run -it --env-file=/Users/user/file1 --env-file=/Users/users/file2 centos:6.6 /bin/bash
Then once in the container:
[user@99964c311fef ~]# env
HOSTNAME=99964c311fef
TER... | ###Instruction: I was just wondering how can i point to two env-files, say /var/app/old/file.conf and /var/market/old/db.conf , 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
docker run -d --hostname=158.6... | I was just wondering how can i point to two env-files, say /var/app/old/file.conf and /var/market/old/db.conf , 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
docker run -d --hostname=158.64.72.80 -d -p 80... | |
My solution for this has been to use the IP as the ID: trim the dots and you get a unique ID that is also available outside of the container to other containers.
With a Service you can get access to the multiple containers's IPs (see my answer here on how to do this:
what's the best way to let kubenetes pods communica... | ###Instruction: 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.
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 ... | 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.
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 kubernetes?
They... | |
Looks like the VPC was not correctly deleted. After deleting manually, the installation proceeded as normal.
| ###Instruction: I started a Kubernetes cluster on AWS using:
wget -q -O - https://get.k8s.io | bash
I then shutdown the cluster. I then tried restarting it and get the following error:
A client error (RouteAlreadyExists) occurred when
calling the CreateRoute operation: The route identified
by 10.246.0.0/24 already ... | I started a Kubernetes cluster on AWS using:
wget -q -O - https://get.k8s.io | bash
I then shutdown the cluster. I then tried restarting it and get the following error:
A client error (RouteAlreadyExists) occurred when
calling the CreateRoute operation: The route identified
by 10.246.0.0/24 already exists.
Any ide... | |
As both a CloudFoundry (past) and Kubernetes (present) commiter, I'm probably uniquely qualified to answer this one.
PaaS-like
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 time to compete in the ... | ###Instruction: The next version of CloudFoundry / Diego will offer native support for Docker containers which will be orchestrated across multible hosts [link].
This sounds very similar to Kubernetes.
Of course, the problem Kubernetes is trying to solve is more a generic, where CloudFoundry is more focussed on app dev... | The next version of CloudFoundry / Diego will offer native support for Docker containers which will be orchestrated across multible hosts [link].
This sounds very similar to Kubernetes.
Of course, the problem Kubernetes is trying to solve is more a generic, where CloudFoundry is more focussed on app development. Howeve... | |
There are several reasons container can fail to start:
the container command itself fails and exits -> check your docker image and start up script to make sure it works.
Use
sudo docker ps -a to find the offending container and
sudo docker logs <container> to check for failure inside the container
a dependency is n... | ###Instruction: I am following the Fedora getting started guide (https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/getting-started-guides/fedora/fedora_ansible_config.md) and trying to run the pod fedoraapache. But kubectl always shows fedoraapache as pending:
POD IP CO... | I am following the Fedora getting started guide (https://github.com/GoogleCloudPlatform/kubernetes/blob/master/docs/getting-started-guides/fedora/fedora_ansible_config.md) and trying to run the pod fedoraapache. But kubectl always shows fedoraapache as pending:
POD IP CONTAINER(S) ... | |
Set an imagePullPolicy of Always on the container
| ###Instruction: Using Kubernetes for deployment:
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.
Now, if i update the Dockerfile, build and push again, without changing its tag then the image is changed in the registry, but... | Using Kubernetes for deployment:
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.
Now, if i update the Dockerfile, build and push again, without changing its tag then the image is changed in the registry, but the host has th... | |
When you create a service, the service will proxy the connection to the different pods.
A service therefore maintains the list of IPs of the pods' containers.
You can then look those up in the API
they will be at
http(s)://${KUBERNETES_SERVICE_HOST}/api/v1/namespaces/${NAMESPACE}/endpoints/${SERVICE_NAME}
NAMESPACE i... | ###Instruction: 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?
Maybe what I want ask is what's the best way... | 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?
Maybe what I want ask is what's the best way to setup multi-... | |
You are right in saying that kubectl rolling-update frontend --image=image:v2 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 Image update is not supported for multi-container pods
But, it certainly gives you 2 variants
kube... | ###Instruction: Is there any way to do a rolling-update with a replication controller that has 2 or more containers?
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... | Is there any way to do a rolling-update with a replication controller that has 2 or more containers?
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 image stored ... | |
UPDATE:
gitRepo is now deprecated
https://github.com/kubernetes/kubernetes/issues/60999
ORIGINAL ANSWER:
going through the code this is what i figured:
- name: data
gitRepo:
repository: "git repo url"
revision: "hash of the commit to use"
after fixing typos in my mountPath, it works fine.
| ###Instruction: Can someone give an example of how to use the gitRepo type of volume in Kubernetes?
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.
especially is there parameters to pull a specific branch, use credentials (username, password, ... | Can someone give an example of how to use the gitRepo type of volume in Kubernetes?
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.
especially is there parameters to pull a specific branch, use credentials (username, password, or SSH key) etc.... | |
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 generated as a random string of 5 alphanumeric characters. However, given that there are more than 60 mi... | ###Instruction: So I'm researching how to use Kubernetes for my case. I installed it and played a bit.
The question is when the replication controller starts couple of replicas they have something like an id in their name:
How unique is this id? Is it uniqueness for the lifetime of kubernetes? Is it unique across diff... | So I'm researching how to use Kubernetes for my case. I installed it and played a bit.
The question is when the replication controller starts couple of replicas they have something like an id in their name:
How unique is this id? Is it uniqueness for the lifetime of kubernetes? Is it unique across different kubernetes... | |
You can use a PullSecret to tell Kubernetes what registry to get your containers from. Please see:
http://releases.k8s.io/release-1.0/docs/user-guide/images.md#specifying-imagepullsecrets-on-a-pod
| ###Instruction: I know how to run a registry mirror
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
and how to use it
docker --registry-mirror=http://10.0.0.2:5000 -d
But how can I use multiple r... | I know how to run a registry mirror
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
and how to use it
docker --registry-mirror=http://10.0.0.2:5000 -d
But how can I use multiple registry mirror.
... | |
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.
You can then use any of a variety of mechanisms to pass that config to your task, e.g. if it's envir... | ###Instruction: 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:
env:
- name: DB_PASSWORD
value: password
which are then available inside the Docker container as the $D... | 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:
env:
- name: DB_PASSWORD
value: password
which are then available inside the Docker container as the $DB_PASSWORD envir... | |
GitHub allows cloning repositories using an OAuth token in https URLs as such:
$ git clone https://$GH_TOKEN@github.com/owner/repo.git
see
https://help.github.com/articles/creating-an-access-token-for-command-line-use/
| ###Instruction: Has anyone mounted a private GitHub repository into a kubernetes pod volume?
What is the best way to achieve this?
I thought of two possible ways:
Using user / password in HTTPS repository URL
Using private SSH key on the machine
I like the second better, but I couldn't figure which user is pulling th... | Has anyone mounted a private GitHub repository into a kubernetes pod volume?
What is the best way to achieve this?
I thought of two possible ways:
Using user / password in HTTPS repository URL
Using private SSH key on the machine
I like the second better, but I couldn't figure which user is pulling the repository to ... | |
Did you do a sudo -s on the node ? You have to be an admin to connect to the docker daemon and do queries using docker command line client.
| ###Instruction: I try to Install Stratos with Kubernetes in a Testing Environment to build Stratos.I downloading the Kubernetes binaries and provisioned a Docker registry to VAGRANT_KUBERNETES_SETUP folder (in 2.c. i in page).But it gives 3 Failed Units(docker.service,setup-network-environment.service and docker.sock... | I try to Install Stratos with Kubernetes in a Testing Environment to build Stratos.I downloading the Kubernetes binaries and provisioned a Docker registry to VAGRANT_KUBERNETES_SETUP folder (in 2.c. i in page).But it gives 3 Failed Units(docker.service,setup-network-environment.service and docker.socket) When I Log i... | |
Hello am kinda new to kubernetes 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.
In case you are deploying Kubernetes on a non cloud enabled providers like for example vagrant /local, etc then some features are not currently offered ... | ###Instruction: 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 lo... | 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, or ... | |
Yes, you can attach to a container in a pod.
Using Kubernetes 1.0 issue the following command:
Do:
kubectl get po to get the POD name
kubectl describe po POD-NAME to find container name
Then:
kubectl exec -it POD-NAME -c CONTAINER-NAME bash Assuming you have bash
Its similar to docker exec -it CONTAINER-NAME WHAT_EVE... | ###Instruction: 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.
On my local VM, I just use docker run to start the two containers and then I use docker attach to attach to... | 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.
On my local VM, I just use docker run to start the two containers and then I use docker attach to attach to the web server ... | |
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.
| ###Instruction: Is there a way to pass environment variables through the services in Kubernetes?
I tried passing it in to my service yaml like this:
apiVersion: v1
kind: Service
metadata:
labels:
name: kafka
name: kafka
spec:
ports:
- port: 9092
selector:
name: kafka
env:
- name: BROKER_ID... | Is there a way to pass environment variables through the services in Kubernetes?
I tried passing it in to my service yaml like this:
apiVersion: v1
kind: Service
metadata:
labels:
name: kafka
name: kafka
spec:
ports:
- port: 9092
selector:
name: kafka
env:
- name: BROKER_ID
value: "1... | |
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.
The main different between upgrade.sh and kube-push.sh is that the... | ###Instruction: What is the recommended way to upgrade a kubernetes cluster as new versions are released?
I heard here it may be https://github.com/kubernetes/kubernetes/blob/master/cluster/kube-push.sh. If that is the case how does kube-push.sh relate to https://github.com/GoogleCloudPlatform/kubernetes/blob/master/c... | What is the recommended way to upgrade a kubernetes cluster as new versions are released?
I heard here it may be https://github.com/kubernetes/kubernetes/blob/master/cluster/kube-push.sh. If that is the case how does kube-push.sh relate to https://github.com/GoogleCloudPlatform/kubernetes/blob/master/cluster/gce/upgra... | |
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.
If so, you need to install this CA cert on the machine you're calling FROM
put your CA cert in
/etc/ssl/certs
and run
update-ca-certificates
sometimes I have had to put it also in... | ###Instruction: So I have deployed a Kubernetes cluster and installed a private Docker registry. Here is my registry controller:
---
apiVersion: v1
kind: ReplicationController
metadata:
name: registry-master
labels:
name: registry-master
spec:
replicas: 1
selector:
name: registry-mas... | So I have deployed a Kubernetes cluster and installed a private Docker registry. Here is my registry controller:
---
apiVersion: v1
kind: ReplicationController
metadata:
name: registry-master
labels:
name: registry-master
spec:
replicas: 1
selector:
name: registry-master
template... | |
There is a quite long default timeout for detecting unreachable nodes and for re-scheduling pods, maybe you did not wait long enough?
You can adjust the timeouts with several flags:
node-status-update-frequency on the kubelet (http://kubernetes.io/v1.0/docs/admin/kubelet.html)
node-monitor-grace-period and pod_evicti... | ###Instruction: I'm currently doing some tests on a kubernetes cluster.
I was wondering why the pods aren't rescheduled in some cases :
When the node is unreachable
When the remote kubelet doesn't answer
Actually the only case when a pod got rescheduled is when the kubelet notify the master.
Is it on purpose ? Why ?
... | I'm currently doing some tests on a kubernetes cluster.
I was wondering why the pods aren't rescheduled in some cases :
When the node is unreachable
When the remote kubelet doesn't answer
Actually the only case when a pod got rescheduled is when the kubelet notify the master.
Is it on purpose ? Why ?
If i shut down a... | |
This is a sample application I used:
{
"kind": "ReplicationController",
"apiVersion": "v1",
"metadata": {
"name": "tess.io",
"labels": {
"name": "tess.io"
}
},
"spec": {
"replicas": 3,
"selector": {
"name": "tess.io"
},
"template": {
"metadata": {
"labels"... | ###Instruction: Can someone give an example of how to use the gitRepo type of volume in Kubernetes?
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.
especially is there parameters to pull a specific branch, use credentials (username, password, ... | Can someone give an example of how to use the gitRepo type of volume in Kubernetes?
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.
especially is there parameters to pull a specific branch, use credentials (username, password, or SSH key) etc.... | |
PVs, like nodes, are not scoped to any namespace. However, as you noted PVCs, are.
| ###Instruction: I am using GKE with kubectl installed from gcloud components.
I have created a pv (gcePersistentDisk) with namespace scope using kubectl.
apiVersion: v1
kind: PersistentVolume
metadata:
name: cstor-cs-a-disk-david
namespace: ns-david
spec:
gcePersistentDisk:
pdName: cstor-cs-a-disk-david
f... | I am using GKE with kubectl installed from gcloud components.
I have created a pv (gcePersistentDisk) with namespace scope using kubectl.
apiVersion: v1
kind: PersistentVolume
metadata:
name: cstor-cs-a-disk-david
namespace: ns-david
spec:
gcePersistentDisk:
pdName: cstor-cs-a-disk-david
fsType: ext4
... | |
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 Subject Alternati... | ###Instruction: 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 kubectl cluster-info command etc. I want to setup something similar like desig... | 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 kubectl cluster-info command etc. I want to setup something similar like design doc - Simple 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 bash-completion as described in the question above.
kubectl patch
kubernetes pull request
Edit: this w... | ###Instruction: Cannot get kubectl bash completion to work on Mac. I installed bash-completion with brew i.e. brew install bash-completion then as per the install notes, added it to the ~/.bash_profile:
if [ -f $(brew --prefix)/etc/bash_completion ]; then
. $(brew --prefix)/etc/bash_completion
fi
But still getting t... | Cannot get kubectl bash completion to work on Mac. I installed bash-completion with brew i.e. brew install bash-completion then as per the install notes, added it to the ~/.bash_profile:
if [ -f $(brew --prefix)/etc/bash_completion ]; then
. $(brew --prefix)/etc/bash_completion
fi
But still getting the error kubectl... | |
If the same docker image is working via kubectl run 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 kubectl get pods <name> -o yaml for both. Shot in the dark: is it possible the env vars spe... | ###Instruction: I'm trying to get a ghost blog deployed on GKE, working off of the persistent disks with WordPress tutorial. I have a working container that runs fine manually on a GKE node:
docker run -d --name my-ghost-blog -p 2368:2368 -d us.gcr.io/my_project_id/my-ghost-blog
I can also correctly create a pod using... | I'm trying to get a ghost blog deployed on GKE, working off of the persistent disks with WordPress tutorial. I have a working container that runs fine manually on a GKE node:
docker run -d --name my-ghost-blog -p 2368:2368 -d us.gcr.io/my_project_id/my-ghost-blog
I can also correctly create a pod using the following m... | |
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 be m... | ###Instruction: Kubernetes volume support is listed here https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md , however it does not currently meet my needs.
I need to support object storage, both Openstack Swift API and S3 compatible API. (k8s does support AWS directly but I can't use i... | Kubernetes volume support is listed here https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md , however it does not currently meet my needs.
I need to support object storage, both Openstack Swift API and S3 compatible API. (k8s does support AWS directly but I can't use it to connect to ... | |
You do not need to run docker pull manually. The pod definition contains the image name to pull and Kubernetes will pull the image for you. You have several options in terms of defining how Kubernetes will decide to pull the image, using the imagePullPolicy: definition in your pod spec. Much of this is documented here,... | ###Instruction: Does Kubernetes download Docker image automatically when i create a pod or should I use Docker pull manually to Download the image locally?
### Response: You do not need to run docker pull manually. The pod definition contains the image name to pull and Kubernetes will pull the image for you. You have ... | Does Kubernetes download Docker image automatically when i create a pod or should I use Docker pull manually to Download the image locally?
| |
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.
Can you explain what you're hoping to achieve?
Edit: if you want to run Consul, nothing is stopping you. Our DNS server is just one implementation.
| ###Instruction: I am running a Kubernetes Cluster on Google Container Engine with the default SkyDNS implementation enabled.
How can I add custom DNS Entries in Google Container Engine? Is there any way to:
Add custom DNS Entries to SkyDNS that will persist if the SkyDNS container is restarted?
Change the default DNS... | I am running a Kubernetes Cluster on Google Container Engine with the default SkyDNS implementation enabled.
How can I add custom DNS Entries in Google Container Engine? Is there any way to:
Add custom DNS Entries to SkyDNS that will persist if the SkyDNS container is restarted?
Change the default DNS Settings on my ... | |
I have no 'inside' knowledge of Borg so this answer is based only on what Google themselves have published here. For much greater detail, you should look into that paper. Section 8 makes specific reference to Kubernetes and is the basis of this answer (along with Kubernetes own docs):
1) Key differences:
Borg groups w... | ###Instruction: 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.
So, I would like to know:
1) In term of containers cluster manageme... | 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.
So, I would like to know:
1) In term of containers cluster management, what's the k... | |
You should be able to use a rolling update specifying the same image name that you are currently using:
kubectl rolling-update <replication-controller-name> --image=foobar/myimage:[branch]-latest
This will (behind the scenes) create a new replication controller that is a copy of your existing replication controller wi... | ###Instruction: I have a kubernetes RC/pod consisting of containers with images like: foobar/my-image:[branch]-latest where "branch" is the git branch ("master", etc).
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 delete th... | I have a kubernetes RC/pod consisting of containers with images like: foobar/my-image:[branch]-latest where "branch" is the git branch ("master", etc).
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 delete the RC and re-crea... | |
If you use Docker v1.7 or above, you may have run into a cadvisor bug, where network stats are not collected correctly. See
https://github.com/kubernetes/kubernetes/issues/13189
The bug has already being fixed in cadvisor, and kubernetes will include the fix soon.
| ###Instruction: I've the a lot of error logs reported by kubelet :
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/veth2fc2... | I've the a lot of error logs reported by kubelet :
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/veth2fc2d33/statistics/r... | |
This is a rather broadly asked question, so I will (and can) answer only in a rather broad manner.
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.:
Cartridges vs. Docker Containers
Gears vs.... | ###Instruction: I'm searching for a main difference between OpenShift V3 and V2.
Is OpenShift V2 working like this?: https://www.openshift.com/walkthrough/how-it-works
And how are Docker and Kubernetes working in V3?
Can someone give me a clear explanation about the build-up of OpenShift V2 and V3
### Response: This i... | I'm searching for a main difference between OpenShift V3 and V2.
Is OpenShift V2 working like this?: https://www.openshift.com/walkthrough/how-it-works
And how are Docker and Kubernetes working in V3?
Can someone give me a clear explanation about the build-up of OpenShift V2 and V3
| |
Yes,Kubernetes supports container and image garbage collection. More details in https://kubernetes.io/docs/concepts/cluster-administration/kubelet-garbage-collection/
You may want to check whether that particular node has enough disk space allocated to host the images for the pods assigned to it.
| ###Instruction: 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:
reason... | 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:
reason: freeDiskSpaceF... | |
UPDATE
According to the docs, the format is now:
_my-port-name._my-port-protocol.my-svc.my-namespace.svc.cluster.local
See the related doc here:
https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pods
ORIGINAL ANSWER:
as of this date, this is actually not possible... but it is being looked at by t... | ###Instruction: On GKE, kube-dns is running on my nodes, I can see the docker containers.
I do have access to Services by name, which is great for all these applications where load balancing is a perfectly suitable solution, but how would I use the DNS to access individual pods?
I know I can look up specific pods in t... | On GKE, kube-dns is running on my nodes, I can see the docker containers.
I do have access to Services by name, which is great for all these applications where load balancing is a perfectly suitable solution, but how would I use the DNS to access individual pods?
I know I can look up specific pods in the API, but I ne... | |
All Docker images can be run on Kubernetes -- it uses Docker to run the images.
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.
If you have anything particular in mind, I'd be interested in hearin... | ###Instruction: How can I find out if a given Docker image can be run using Kubernetes?
What should I do to help ensure that my images will run well in any Kubernetes-managed environment?
### Response: All Docker images can be run on Kubernetes -- it uses Docker to run the images.
You can expose ports from container... | How can I find out if a given Docker image can be run using Kubernetes?
What should I do to help ensure that my images will run well in any Kubernetes-managed environment?
| |
This is something we want to support, and is/was underway (see PR 7053), but it is not yet possible.
You can observe the status/progress on:
https://github.com/kubernetes/kubernetes/issues/341
It's possible to work around the lack of this feature by creating a new label that would match the selector you'd like and the... | ###Instruction: Is it possible to specify a set-based label selector 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 the appropriate documentation, that would be helpful.
### Response: This is something we w... | Is it possible to specify a set-based label selector 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 the appropriate documentation, that would be helpful.
| |
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.
In this case, something like:
export MINION_SIZE=t2.large
Should run forever.[2]
[1] http... | ###Instruction: 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.
Question is why? Or alternatively, how do I replace the master node on AWS? Or alternativ... | 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.
Question is why? Or alternatively, how do I replace the master node on AWS? Or alternatively, how do I de... | |
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 wh... | ###Instruction: I'm having quite a bit of fun with the gcePersistentDisk in the context of pods inside of kubernetes:
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 d... | I'm having quite a bit of fun with the gcePersistentDisk in the context of pods inside of kubernetes:
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 difficult than I ... | |
This will let you send stdin to a container:
kubectl exec -i POD_NAME COMMAND
Or
kubectl attach -i POD_NAME
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
| ###Instruction: I have a kubernetes cluster running on coreos. I wish to run journal2gelf https://github.com/systemd/journal2gelf 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 streaming logs elsewhere). Is it possible to configure a... | I have a kubernetes cluster running on coreos. I wish to run journal2gelf https://github.com/systemd/journal2gelf 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 streaming logs elsewhere). Is it possible to configure a pod to allow es... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.