prompt stringlengths 65 38.7k | response stringlengths 41 29.1k |
|---|---|
<p>I initially setup a cluster with the <code>kube-up.sh</code> utility on AWS. Now I ran out of capacity and I'm looking for a simple way to extend my cluster with more nodes. </p>
<p>Is there a 'simple' way to add more nodes to a running cluster on AWS? I've been reading all the docs but cannot seem to find a way. <... | <p>If you used kube-up, your minions should be launched into an auto-scaling group, and you should just be able to change the size of that auto-scaling group.</p>
<p>This question is a few months old, so I'm not sure whether this was the case back in July, but it should definitely be the case now.</p>
<p>I'm also wor... |
<p>I'm struggling with the Kubernetes Go library. The docs--<a href="https://github.com/kubernetes/kubernetes/blob/master/pkg/client/unversioned/doc.go">at least the ones I found</a>--appear out-of-date with the library itself. The example provided does not build because of issues with the imports. I'm just trying t... | <p>So after a little experimentation and a hint from the k8s Slack channel, I have this example. Perhaps someone can update the example with a proper import path.</p>
<pre><code>package main
import (
"fmt"
"log"
"github.com/kubernetes/kubernetes/pkg/api"
client "github.com/kubernetes/kubernetes/pkg/... |
<p>I'm busy testing out kubernetes on my local pc using <a href="https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/docker.md" rel="nofollow">https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/docker.md</a> </p>
<p>which launches a dockerized single node <cod... | <p>Update: Privileged mode is now enabled by default (both in the apiserver and in the kubelet) starting with the 1.1 release of Kubernetes. </p>
<hr>
<p>To enable privileged containers, you need to pass the <code>--allow-privileged</code> flag to the Kubernetes apiserver <em>in addition</em> to the Kubelet when it s... |
<p>I reinstalled some nodes and a master. Now on the master I am getting:</p>
<blockquote>
<p>Sep 15 04:53:58 master kube-apiserver[803]: I0915 04:53:58.413581 803 logs.go:41] http: TLS handshake error from $ip:54337: remote error: bad certificate</p>
</blockquote>
<p>Where $ip is one of the nodes.</p>
<p>So I lik... | <p>Take a look through the <a href="https://kubernetes.io/docs/admin/authentication/" rel="nofollow noreferrer">Creating Certificates</a> section of authentication.md. It walks you through the certificates that you need to create and how to pass them to the system components, and you should be able to use that to re-ge... |
<p>I see in the <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/v0.21.3/docs/volumes.md">docs</a> how do do this for pods, but I want to use a replication controller to manage my pods, ensuring that there is always one up at all times.</p>
<ol>
<li><p>How can I define a replication controller where the... | <p>Using a persistent volume in a Replication Controller works great for shared storage. You include a persistentVolumeClaim in the RC's pod template. Each pod will use the same claim, which means it's shared storage. This also works for read-only access in gcloud if your Replica count > 1.</p>
<p>If you wanted dis... |
<p>I'm using a SimpleProducer in the python kafka-library.
This script has worked flawlessly previously with other more hard-configured kafka-setups I've tried.</p>
<pre><code>kafka = KafkaClient(u'[masterNodeIp]:[servicePort]')
producer = SimpleProducer(kafka)
#make a simple message, while true run
producer.send_mess... | <pre><code>broker.id=10200121
host.name=kafka-f8p06 <----- use IP here
advertised.host.name=kafka-f8p06 <---- use IP here
</code></pre>
<p>I think you should have IPs for <code>host.name</code> and <code>advertised.host.name</code> as K8s does not resolve Pods by hostname but it does by IP.</p>
<p>Your kafka ... |
<p>We are trying to Configure kubernetes RC in AWS instance with AWS Elastic Block Store(EBS). here is the key part of our controller yaml file -</p>
<pre><code> volumeMounts:
- mountPath: "/opt/phabricator/repo"
name: ebsvol
volumes:
-
name: ebsvol
awsElasticBlockStore:
... | <p>We opened an issue to discuss this:
<a href="https://github.com/kubernetes/kubernetes/issues/13858" rel="nofollow">https://github.com/kubernetes/kubernetes/issues/13858</a></p>
<p>The recommended way to go here is to use IAM instance profiles. kube-up does configure this for you, and if you're not using kube-up I... |
<p>I am working on a Java application which deploys web artifacts in Apache Tomcat Docker Containers with the use of Google Kubernetes. I am using <a href="https://github.com/spotify/docker-client" rel="nofollow">https://github.com/spotify/docker-client</a> in order to carry out Docker Image and Container handling acti... | <p>Unfortunately I'm not familiar with the Java client library.</p>
<p>My suggestion would be to try using the regular command-line client (kubectl). If that works, then you know the problem is in the Java client library or your usage of it. If using the command line client doesn't work, then there will be more people... |
<p>I use DNS in kubernetes. and test result like:</p>
<pre><code>core@core-1-86 ~ $ kubectl exec busybox -- nslookup kubernetes
Server: 10.100.0.10
Address 1: 10.100.0.10
Name: kubernetes
Address 1: 10.100.0.1
</code></pre>
<p>And then I entried to busybox container, and ping kubernetes, like:</p>
<pre><cod... | <p>The kubernetes service is a virtual IP and doesn't currently handle ICMP requests (see #<a href="https://github.com/kubernetes/kubernetes/issues/2259" rel="nofollow">2259</a>). You should be able to verify connectivity to the kubernetes service using a TCP connection, e.g. <code>curl https://kubernetes/</code>. </p>... |
<p>I have a kubernetes service called <code>staging</code> that selects all <code>app=jupiter</code> pods. It exposes an HTTP service on port 1337. Here's the describe output:</p>
<pre><code>$ kubectl describe service staging
Name: staging
Namespace: default
Labels: run=staging
Selector: a... | <p>IP is the address of your service, which remains constant over time. Endpoints is the collection of backend addresses across which requests to the service address are spread at a given point in time. That collection changes every time the set of pods comprising your service changes, as you've noticed when performin... |
<p>I have a Kubernetes cluster that was initialized using the <code>kube-up.sh</code> script inside AWS, and occasionally there's a very slow DNS lookup when finding one service from inside another pod. Here's the basic picture:</p>
<pre><code> (browser)
|
V
(ELB)
|
V
(front-en... | <p>There was a bug that was fixed here (<a href="https://github.com/kubernetes/kubernetes/pull/13345" rel="nofollow">https://github.com/kubernetes/kubernetes/pull/13345</a>) that has been shown to cause this problem in Kubernetes clusters 1.0.5 and older. The problem is fixed in the <a href="https://github.com/kuberne... |
<p>I have a Kubernetes service on GKE as follows:</p>
<pre><code>$ kubectl describe service staging
Name: staging
Namespace: default
Labels: <none>
Selector: app=jupiter
Type: NodePort
IP: 10.11.246.27
Port: <unnamed> 80/TCP
NodePort: <... | <p>Service IPs are virtual IPs managed by kube-proxy. So, in order for that IP to be meaningful, the client must also be a part of the kube-proxy "overlay" network (have kube-proxy running, pointing at the same apiserver).</p>
<p>Pod IPs on GCE/GKE are managed by GCE <a href="https://cloud.google.com/compute/docs/netw... |
<p>The <code>kubernetes</code> service is in the <code>default</code> namespace. I want to move it to <code>kube-system</code> namespace. So I did it as follow:</p>
<pre class="lang-yaml prettyprint-override"><code>kubectl get svc kubernetes -o yaml > temp.yaml
</code></pre>
<p>This generates <code>temp.yaml</code> ... | <p>Name and namespace are immutable on objects. When you try to change the namespace, <code>replace</code> looks for the service in the new namespace in order to overwrite it. You should be able to do <code>create -f ...</code> to create the service in the new namespace</p>
|
<p>We have a private kubernetes cluster running on a baremetal CoreOS cluster (with Flannel for network overlay) with private addresses.</p>
<p>On top of this cluster we run a kubernetes ReplicationController and Service for elasticsearch. To enable load-balancing, this service has a ClusterIP defined - which is also ... | <p>You need to set the <code>type</code> of your Service.</p>
<p><a href="http://docs.k8s.io/v1.0/user-guide/services.html#external-services" rel="nofollow">http://docs.k8s.io/v1.0/user-guide/services.html#external-services</a></p>
<p>If you are on bare metal, you don't have a LoadBalancer integrated. You can use No... |
<p>I need to encrypt the data on a block device and allow the Pod to access it as a volume.</p>
<p>I noticed its now possible on Google cloud to encrypt a new disk using <a href="https://cloud.google.com/compute/docs/disks/customer-supplied-encryption" rel="nofollow">Customer-Supplied Encryption Keys</a></p>
<p>Can I... | <p>My reading of the the Google docs (<a href="https://cloud.google.com/compute/docs/disks/customer-supplied-encryption" rel="nofollow">https://cloud.google.com/compute/docs/disks/customer-supplied-encryption</a>) are that no key is required to mount the disk. The keys are only provided at disk creation time.</p>
<p>... |
<p>So I am hesitant to ask as a newbie but I have hit a wall. I am following:</p>
<p><a href="http://www.projectatomic.io/docs/gettingstarted/" rel="nofollow noreferrer">http://www.projectatomic.io/docs/gettingstarted/</a></p>
<p>Using fedora atomic host 22 latest.</p>
<p>I had trouble getting the system up with so... | <p>That guide probably needs to be updated, given that the kubernetes v1beta3 api was deprecated in <a href="https://github.com/kubernetes/kubernetes/pull/11737" rel="nofollow">July</a>. I suspect you're running a recent build of the apiserver (which supports only the v1 api), but older builds of kube-proxy/kubelet.</p... |
<p>Both the Kubernetes <a href="http://kubernetes.io/v1.0/docs/admin/high-availability.html" rel="nofollow">HA guide</a> and the <a href="http://kubernetes.io/v1.0/docs/getting-started-guides/scratch.html" rel="nofollow">From Scratch guide</a> recommend running Etcd, kube-apiserver, kube-controller-manager, and kube-sc... | <p>The biggest benefit is streamlined setup for most people. Running a few <code>docker run</code> commands is way easier than downloading binaries, unpacking, fine-tuning init scripts (which are different on every distro), running a supervisor, etc. We have a pretty good process manager - relying on that is powerful... |
<p>I would like to achieve the following functionality:</p>
<ul>
<li>when a given pod (let's call it application pod) is deployed on a
node, another pod providing an ephemeral volume is deployed before
that, if such "volume pod" has not existed on the target node yet </li>
<li>the number of application pods can be sca... | <p>We do not support dependencies at the moment. In the future will support a "daemon" scheduler which can run a pod on every node, but not only if some other pod is being scheduled to a node. In the future we might support existence dependencies, but that's more for creation: create Pod P iff Service S exists.</p>
... |
<p>I'm trying to setup Kubernetes in Openstack + CoreOS. </p>
<p>I have master 10.240.63.84 and 2 minions .63 and .83. I also created 3 redis pods:</p>
<pre><code>redis-gopher-gziey 10.244.32.2 10.240.63.66/10.240.63.66
redis-managed-oh43e 10.244.32.3 10.240.63.66/10.240.63.66
redis-primary-fplln ... | <p>This sort of thing is hard to debug remotely. Things I would check:</p>
<p>1) on the sender: <code>iptables -t raw -I OUTPUT -d 10.244.32.2 -j TRACE; dmesg -c > /dev/null; ncat -v -t 10.244.32.2 6379; dmesg;</code></p>
<p>This will give you some insight into what the kernel is doing.</p>
<p>2) on the sender: ... |
<p>Kubernetes create a load balancer, for each service; automatically in GCE. How can I manage something similar on AWS with juju?</p>
<p>Kubernetes service basically use the kubeproxy to handle the internal traffic. But that kubeproxy ip its do not have access to the external network.</p>
<p>There its a way to accom... | <p>I can't speak to juju specifically, but Kubernetes supports Amazon ELB - turning up a load-balancer should work.</p>
|
<p>I can't find out customer real IP address when apache-php enviroment runs in google container. Without modifying anything, I get ip address from container address range, when using mod_remoteip, I can add</p>
<pre><code>RemoteIPHeader X-Client-IP
RemoteIPInternalProxyList ournet/proxy-list
</code></pre>
<p>and add... | <p>Some traffic is masqueraded, but it is done at L3, rather than L7, so there's no way to add a header. :(</p>
<p>This will get better soon for in-cluster traffic, but we have to wait for cloud load-balancers to catch up before we can properly handle out-of-cluster traffic properly.</p>
|
<p>I'm searching for the answer but i didn't find it anywhere.
Is it possible to share a service between multiple namespaces ?</p>
<p>For instance, if i have 2 namespaces (let's say 'qa' and 'dev'), is it possible to use the same database server ?
The database server would be preferably managed by kubernetes too.</p>... | <p>Services are accessible from all namespaces as long as you address them using both the name and the namespace.</p>
<p>For example, if you have a service named <code>db</code> in namespace <code>dev</code>, you can access it using the DNS name <code>db</code>. While this won't work from <code>qa</code>, you can acce... |
<p>I created cluster in gcloud with three nodes. So far so good.Thereafter i tried to run the pod.. it is giving error.. I found out the kubectl is not configured correct.. Getting following error when I try to run the pod.. Appreciate any help in this regard.</p>
<p>error: could not read an encoded object from nodejs... | <p>If your kubectl configuration is incorrect after creating a cluster, you can always run <code>gcloud container clusters get-credentials NAME</code> (see <a href="https://cloud.google.com/container-engine/docs/clusters/operations#configuring_kubectl" rel="noreferrer">configuring kubectl</a>) to restore a working kube... |
<p>To use cinder volumes I added the options --cloud-provider and --cloud-config to my kubelet configuration:</p>
<pre><code>$ cat /etc/kubernetes/kubelet
###
# kubernetes kubelet (node) config
# The address for the info server to serve on (set to 0.0.0.0 or "" for all interfaces)
KUBELET_ADDRESS="--address=0.0.0.0"
... | <p>The error messages are not so clear in the openstack cloud provider plugin.
It wont register if the there is any unexpected field in the config file, it will throw an error, which unfortunately is not properly bubbled.</p>
<p>Here are the fields (and their identifiers) that are recognized by the plugin</p>
<p><cod... |
<p>Did Google publish a whitepaper on Kubernetes, of a similar style as <a href="http://research.google.com/pubs/pub43438.html" rel="nofollow">Borg</a>?</p>
<p>I am aware of <a href="http://kubernetes.io/v1.0/" rel="nofollow">end-user documentation</a> and it would likely explain a lot what I am looking for, but I fin... | <p>Perhaps you are looking for <a href="http://research.google.com/pubs/pub43826.html" rel="noreferrer">David Rensin's small book on Kubernetes</a>? It is listed with other Google research papers, although it is more of an brief introduction/overview and less a whitepaper (like the <a href="http://research.google.com/p... |
<p>I need to set environment variable in kubernetes slave which is a coreos system.
I have tried using <code>export</code>and <code>declare</code> but it keeps reading each argument as a separate command</p>
| <p>don't set variables in the <code>command</code> field, take a look at the <code>env</code> field.</p>
|
<pre>
core@core-1-94 ~ $ kubectl exec -it busybox -- nslookup kubernetes
Server: 10.100.0.10
Address 1: 10.100.0.10
nslookup: can't resolve 'kubernetes'
core@core-1-94 ~ $ kubectl get svc --namespace=kube-system
NAME LABELS SELECTOR ... | <p>For DNS to work, the kubelet needs to be passed the flags --cluster_dns= and --cluster_domain=cluster.local at startup. This flag isn't included in <a href="https://github.com/GoogleCloudPlatform/kubernetes/blob/master/hack/local-up-cluster.sh#L240-L247" rel="noreferrer">the set of flags passed to the kubelet</a>, s... |
<p>Running CoreOS, etcd is not secured by default. To secure it I can use TLS, which adds a level of complexity I'm willing to work on. </p>
<p>Now, is Kubernetes able to use a TLS secured etcd cluster? </p>
<p>In the config for the kubelet and various pods, Kubernetes passes the etcd endpoints as parameters, so they... | <p>The API server is the only component that speaks directly to etcd. When starting the API server, you can pass a <code>--etcd-config=/path/to/client/config</code> parameter instead of just pointing to an unsecured etcd server with <code>--etcd-server</code></p>
<p>In that config file, you would specify the etcd serv... |
<p>I have one successfully working cluster, with out any problems, I've tried to make a copy of it. It's working basically, except one issue - token generated by apiserver is not valid with error message:</p>
<pre><code>6 handlers.go:37] Unable to authenticate the request due to an error: crypto/rsa: verification erro... | <p>So, apparently it was wrong server.key used by controller manager.
According to <a href="http://kubernetes.io/v1.0/docs/admin/service-accounts-admin.html" rel="nofollow">kubernetes documentation</a> token is generated by controller manager. </p>
<p>While I was doing copy of the all my configuration, I had to chang... |
<p>So Google Kubernetes is a Docker container cluster management solution that helps deploy, scale, schedule and maintenance sets of containers simple.</p>
<p>Apache Mesos is a work scheduler that figures out where jobs (e.g. deploying a Docker container, some batch processing job, etc.) should run.</p>
<p>Kubernetes... | <p>I recently gave a presentation at the London Mesos User Group, addressing exactly this question: <a href="https://speakerdeck.com/mhausenblas/can-i-have-mesos-and-kubernetes" rel="noreferrer">Can I have Mesos and Kubernetes?</a> with a demo available <a href="https://gist.github.com/mhausenblas/07c03d4230a5e6ec3b46"... |
<p>I am using containers to run both app servers & Cassandra nodes.</p>
<p>When starting the app server container, I need to specify which Cassandra node(1..n) to connect to. How would you divide the workload?</p>
<ol>
<li>One app container to one or more Cassandra nodes(How many).</li>
<li>One or more app containe... | <p>Please see:</p>
<p><a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/examples/cassandra/README.md" rel="nofollow">https://github.com/kubernetes/kubernetes/blob/release-1.0/examples/cassandra/README.md</a></p>
<p>for a tutorial of how to run Cassandra on Kubernetes.</p>
<p>You will also need to ad... |
<p>I am trying to configure php phabricator example from kubernetes but after creating the replication controller. POD is not showing in ready state ever. It shows in below state:</p>
<pre><code>NAME READY STATUS RESTARTS AGE
phabricator-controller-z0nk3 0/1 CrashLoo... | <p>This Pod is crash-looping. You can tell because the number of restarts is greater than zero.</p>
<pre><code>kubectl describe pods <pod-name>
</code></pre>
<p>Should give further details to help debug. As will</p>
<pre><code>kubectl logs <pod-name>
</code></pre>
|
<p>I'm reading the <a href="http://kubernetes.io/v1.0/docs/getting-started-guides/scratch.html" rel="nofollow">Kubernetes "<em>Getting Started from Scratch</em>" Guide</a> and have arrived at the dreaded <a href="http://kubernetes.io/v1.0/docs/admin/networking.html#kubernetes-model" rel="nofollow"><strong>Network Secti... | <p>Docker's standard <a href="https://docs.docker.com/articles/networking/" rel="noreferrer">networking configuration</a> picks a container subnet for you out of its <a href="https://github.com/docker/docker/blob/master/vendor/src/github.com/docker/libnetwork/drivers/bridge/setup_ipv4.go#L25" rel="noreferrer">chosen de... |
<p>I have to get the real ip from the request in my business.actually I got the <code>10.2.100.1</code> every time at my test environment. any way to do this ?</p>
| <p>This is the same question as <a href="https://stackoverflow.com/questions/32723675/gce-k8s-accessing-referral-ip-address">GCE + K8S - Accessing referral IP address</a> and <a href="https://stackoverflow.com/questions/32112922/how-to-read-client-ip-addresses-from-http-requests-behind-kubernetes-services">How to read ... |
<p>We are using Heat + Kubernetes (V0.19) to manage our apps. When do rolling update, sometimes container staring will always fail on a node but kubelet on the node will always retry but always fail. So the updating will hang there which is not the behavior we expected.</p>
<p>I found that using "kubectl delete node" ... | <p>If you just want to cancel the rolling update, remove the failed pods and try again later, I have found that it is best to stop the update loop with <code>CTRL+c</code> and then delete the replication controller corresponding to the new app that is failing. </p>
<pre><code> ^C
kubectl delete replicationcontr... |
<p>Running CoreOS, etcd is not secured by default. To secure it I can use TLS, which adds a level of complexity I'm willing to work on. </p>
<p>Now, is Kubernetes able to use a TLS secured etcd cluster? </p>
<p>In the config for the kubelet and various pods, Kubernetes passes the etcd endpoints as parameters, so they... | <p>digging further and asking on the github project, I was directed towards this post that I hope answers the question: </p>
<p><a href="https://groups.google.com/forum/#!topic/google-containers/bTfEcRQ3N28/discussion" rel="nofollow">https://groups.google.com/forum/#!topic/google-containers/bTfEcRQ3N28/discussion</a><... |
<p>Kubernetes has a pretty complicated networking model that <em>appears</em> to be predicated upon circumventing a critical flaw with Docker's default networking:</p>
<p>By default Docker containers cannot be contacted directly from the outside world, because their IP addresses are local/private to the subnet they're... | <p>This is well described in the <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/design/networking.md#model-and-motivation" rel="nofollow">motivation section of Kubernetes's networking design doc</a>.</p>
<p>Essentially, relying on port binding requires dynamic port mapping to avoid conflicts b... |
<p>This is my first time using google cloud platform and feeling a bit lost. </p>
<p>I pushed my custom ubuntu image (created from a Dockerfile) to GCE and then created a container cluster from the console.</p>
<p>What I got is: a container cluster and a vm instances cluster. </p>
<p>I can ssh into these instances a... | <p>To log into a container, use the following command:</p>
<pre><code>kubectl exec -it POD bash
</code></pre>
<p>Replace <code>POD</code> with the name of the pod in which the container is running. This works for pods with a single container. For pods with multiple containers, use the <code>-c</code> option to specif... |
<p>I need to set environment variable in kubernetes slave which is a coreos system.
I have tried using <code>export</code>and <code>declare</code> but it keeps reading each argument as a separate command</p>
| <pre><code>apiVersion: v1
kind: ReplicationController
metadata:
labels:
name: api
name: api
spec:
replicas: 1
selector:
name: api
template:
metadata:
labels:
name: api
spec:
containers:
- env:
- name: VARIABLE <---- declare an env variable NAME
... |
<p>I try to serve 2 web applications that should be powered by hhvm. It is easy to build up one docker image that includes nginx and the default.conf. But now where I will get <code>n</code> apps as microservices I want to test them and share the nginx container as I proceed with others like DB e.g.</p>
<p>So when ngi... | <p>Yeah, you can create another nginx container with an <code>nginx.conf</code> that is configured similarly to this:</p>
<pre><code>upstream api {
# Assuming this nginx container can access 127.0.0.1:5000
server 127.0.0.1:3000;
server server2.local.io:3000;
}
upstream booking {
# Assuming this nginx cont... |
<p>When I do a <code>kubectl describe <pod></code>, the bottom section has an "Events" section, displaying Events related to that pod. For example, an event with Reason "failedScheduling", with the message "Failed for reason PodFitsResources and possibly others"</p>
<p>How can I query the API to return that lis... | <p>I think events support a fieldSelector for the involved object kind and name</p>
<p>You can also turn the verbosity level on kubectl up to 8 to see network traces to see what it is doing</p>
|
<p>So I'm trying to wrap my head around what exactly a typical Kubernetes pod looks like. According to <a href="http://kubernetes.io/v1.0/docs/user-guide/pods.html" rel="nofollow">their docs</a>, a <em>pod</em>:</p>
<blockquote>
<p>"<em>A pod (as in a pod of whales or pea pod) corresponds to a colocated group of app... | <p>A Pod is the basic scheduling unit in Kubernetes. It is the common case that a pod will only have a single container running in it, as most containers can be scheduled independently (i.e. they do not need to be co-located on the same machine).</p>
<p>With regards to your example, you could put most containers in in... |
<p>As I understand it, kube-proxy runs on every Kubernetes node (it is started on Master and on the Worker nodes)</p>
<p>If I understand correctly, it is also the 'recommended' way to access the API (see: <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/accessing-the-cluster.md#access... | <p>There are a couple options here, as noted in the doc link you provided.</p>
<p>The preferred method is using <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/service-accounts.md" rel="noreferrer">Service Accounts</a> to access the API:</p>
<p>The short description is that your ser... |
<p>We are using kubernetes provided by "Google Container Engine" with enabled "Cloud Logging" feature. But we need to configure fluentd for our application (add more information about application what runs in container).</p>
<p>I can't find any information how I can add my configs to logging agent provided by google a... | <p>There isn't an easy way to customize the fluentd configuration in Google Container Engine (and if you try to customize it, your changes will be lost if a node gets replaced by the instance group manager or during a node upgrade). </p>
<p>If you want to run a custom fluentd configuration, you should disable cloud lo... |
<p>So Kubernetes has a pretty novel network model, that I believe is based on what it perceives to be a shortcoming with default Docker networking. While I'm still struggling to understand: (1) what it perceives the actual shortcoming(s) to be, and (2) what Kubernetes' general solution is, I'm now reaching a point wher... | <p>For a general introduction into kubernetes networking, I found <a href="http://www.slideshare.net/enakai/architecture-overview-kubernetes-with-red-hat-enterprise-linux-71" rel="nofollow noreferrer">http://www.slideshare.net/enakai/architecture-overview-kubernetes-with-red-hat-enterprise-linux-71</a> pretty helpful.<... |
<p>I have successfully shelled into a RUNNING docker container using</p>
<p>docker exec -i -t 7be21f1544a5 bash</p>
<p>I have made some changes to some json files and wanted to apply these changes to reflect online.</p>
<p>I am a beginner and have tried to restart, mount in vain. What strings I have to replace when ... | <p>You can run either create a Dockefile and run:</p>
<pre><code>docker build .
</code></pre>
<p>from the same directory where your <code>Dockerfile</code> is located.</p>
<p>or you can run:</p>
<pre><code>docker run -i -t <docker-image> bash
</code></pre>
<p>or (if your container is already running)</p>
<... |
<p>I've successfully <a href="https://cloud.google.com/container-registry/#pushing_to_the_registry" rel="nofollow">pushed my Docker container image to gcr.io</a> with the following command:</p>
<p><code>$ gcloud docker push gcr.io/project-id-123456/my-image</code></p>
<p>But when I try to <a href="https://cloud.googl... | <p>Ok, after digging around in the Docker code base, I think I have found some similar reports of what you are seeing.</p>
<p>The way this error is displayed changed in 1.7, but this thread seems related:
<a href="https://github.com/docker/docker/issues/14792" rel="nofollow">https://github.com/docker/docker/issues/... |
<p>Is there any way to access the 'internal' services (those not exposed outside) of the cluster in a secure way from the outside.</p>
<p>The goal is simple: I need to debug clients of those services and need to access them, but don't want to expose them outside.</p>
<p>On a regular single host I would normally tunne... | <p>You can do this with a combination of running <code>kubectl proxy</code> on your dev machine and using the proxying functionality built into the master (that's a lot of proxying, but bear with me). </p>
<p>First, run <code>kubectl proxy</code>. Note the port that is bound locally (it should be 8001 by default). Thi... |
<p>I'm trying to bring kubernetes api server up using etcd config (kubernetes uses go-etcd which has a method to read all parameters from a configuration file):</p>
<pre><code>{
"cluster": {
"machines": [ "https://my-public-hostname:2379" ]
},
"config": {
"certFile": "/etc/ssl/etcd/client.pem",
"key... | <p>Finally I find out what was causing this problem. Timeout was not defined correctly because <code>go-etcd</code> unmarshalls json timeout value into time.Duration which uses nanoseconds as a base unit. So that for a value of 1s, 1000000000 should be written.</p>
<p>Following the example above:</p>
<pre><code>{
... |
<p>is there a way to setup automatic external ip allocation to service like google do in loadbalancer ?
I'm running kubernetes on bare metal.</p>
<p>Thank you</p>
| <p>Use services with type nodePort, it will bind your service to a fixed port on all your nodes (<a href="http://kubernetes.io/v1.0/docs/user-guide/services.html#type-nodeport" rel="nofollow">http://kubernetes.io/v1.0/docs/user-guide/services.html#type-nodeport</a>)</p>
<p>Then you have to use a loadbalancer (i.e hapr... |
<p>I experience very strange behavior when I'm trying to set new Kubernetes cluster in AWS.</p>
<p>Whenever I try to run kube-up.sh with its default config it works perfectly,
The cluster and all its relative components are setting up in less than 10 minutes.</p>
<p>The problem occur when I set the "kube-aws-zone" to... | <p>The problem was specific for us-east-1 region.
I had to edit the dhcp-set that was created as part of kube-up.sh and add the following - </p>
<blockquote>
<p>domain-name = ec2.internal</p>
</blockquote>
<p>Then it worked like charm.</p>
<p>More information - <a href="https://github.com/kubernetes/kubernetes/iss... |
<p>I have an app running on port 31280 exposed via nodePorts from a Kubernetes cluster. Same port is exposed through named-port on the instance group used by cluster for load balancing. While creating a backend-service with HTTP protocol, the service is created at default http port(80) even if I specify custom named-po... | <p>EDIT: I was wrong. It does seem to work. I had a typo in my script.</p>
<p>My script is here - I literally just ran this and it worked properly.</p>
<p><a href="https://gist.github.com/thockin/36fea15cc0deb08a768a" rel="nofollow">https://gist.github.com/thockin/36fea15cc0deb08a768a</a></p>
<p>Original response ... |
<p>How can I output the PodSpec of a replication controller using kubectl?</p>
<p>I tried
<code>
kubectl describe rc <name>
</code></p>
<p>but the output doesn't include the PodSpec.</p>
| <p>You can see the <code>pod.spec</code> for a replicationController using <code>kubectl get</code> and the <code>--output=json</code> or <code>--output-yaml</code> arguments. Something like this should work:</p>
<pre><code>kubectl get rc <rc_name> --output=yaml
</code></pre>
|
<p>I'm starting a container using kubernetes and I have to send a -v parameter to docker. I'm searching for it about 3 hours and no success.
Here you can see my run command:</p>
<p><code>kubectl run api --image=${API_IMAGE} --port=${PORT_SERVICE} --overrides='{"apiVersion": "v1","spec": {"template": {"spec": {"contain... | <p>You want to use the <a href="https://github.com/kubernetes/kubernetes/blob/release-1.0/docs/user-guide/volumes.md" rel="nofollow">Volumes</a> construct, which is quite well explained in the docs and used in a number of examples.</p>
<p>If you want to use a host directory, use the <code>hostPath</code> volume type. ... |
<p>If I create this pod:</p>
<pre><code>apiVersion: v1
kind: Pod
metadata:
name: dsm-manager
spec:
containers:
- name: dsm-manager
image: ******
imagePullPolicy: Always
command:
- /sbin/init
volumeMounts:
- mountPath: /srv/project/DSMManager/snapshots
name: dsm-snapshot-storage
volumes:
- name: dsm-snapshot-storage
aw... | <p>This is likely caused by a bug in the Kubernetes EBS management code, and should be fixed by <a href="https://github.com/kubernetes/kubernetes/pull/14493">PR #14493</a>. To summarize, not validating the device block cache was causing the kubelet to think the disk was still attached after it had actually been detache... |
<p>I have built a 4 node kubernetes cluster running multi-container pods all running on CoreOS. The images come from public and private repositories. Right now I have to log into each node and manually pull down the images each time I update them. I would like be able to pull them automatically.</p>
<ol>
<li>I have t... | <p>To add to what @rob said, as of docker 1.7, the use of .dockercfg has been deprecated and they now use a ~/.docker/config.json file. There is support for this type of secret in kube 1.1, but you must create it using different keys/type configuration in the yaml: </p>
<p>First, base64 encode your <code>~/.docker/con... |
<p>I've read documentation, I've seen exemples, but I don't know why would I add a serviceAccount in my pods ?</p>
<p>The 'elasticsearch' exemple from Kubernetes (<a href="https://github.com/kubernetes/kubernetes/tree/master/examples/elasticsearch" rel="noreferrer">https://github.com/kubernetes/kubernetes/tree/master... | <p>The service accounts inject authentication credentials into the pod to talk to the Kubernetes service (e.g. the apiserver). </p>
<p>This is important if you are building an application that needs to inspect the pods/services/controllers that are running in the cluster to have correct behavior. For example, the kube... |
<p>I am using kube go client with kube api to access kube data. I am currently not finding any api call for logs of a particular pod.</p>
<pre><code>kubectl logs pod-name
</code></pre>
<p>returns the logs for a particular pod. How do I do this using go client?
I am using v1.0.6 of kubernetes.</p>
<p>I can get the p... | <p><a href="https://pkg.go.dev/k8s.io/client-go@v0.20.2/kubernetes/typed/core/v1#PodExpansion" rel="nofollow noreferrer">Client Go</a> has offered a function <code>GetLogs</code> for this, which has been answered in <a href="https://stackoverflow.com/questions/53852530/how-to-get-logs-from-kubernetes-using-golang/53870... |
<p>I'm interested in watching a stream of Events from Kubernetes, to determine whether a deployment was successful, or if any of the Pods were unable to be scheduled.</p>
<p>I could call the endpoint <code>/api/v1/watch/events</code>, or I could call <code>/api/v1/events?watch=true</code>. Is there a difference betwee... | <p>We're making <code>watch</code> a query param and removing it from the path (legacy form). You should call <code>/api/v1/events?watch=true</code>. See more discussions <a href="https://github.com/kubernetes/kubernetes/issues/8337" rel="nofollow">here</a> if you're interested. </p>
|
<p><br>
I have problem with containers <code>garbage collection</code>.
<br>
When I start <code>kubelet</code> I have an error:</p>
<pre><code>E1006 08:04:08.856100 25155 kubelet.go:682] Image garbage collection failed: unable to find data for container /
</code></pre>
<p>And <code>garbage collection</code> doesn't... | <p>The error message is from cadvisor, which gathers container stats. You can try <code>curl http://127.0.0.1:4194/validate/</code> on your node and to see if there is any problem preventing cadvisor from functioning correctly.</p>
<p>Unlike image garbage collection (GC), container GC does not rely on cadvisor. You ma... |
<p>If I create 3 nodes in a cluster, how do I distribute the docker containers evenly across the containers? For example, if I create a cluster of 3 nodes with 8 cpus on each node, I've determined through performance profiling that I get the best performance when I run one container per cpu.</p>
<pre><code>gcloud cont... | <p>Both your and jpapejr's solutions seem like they'd work, but using a <code>nodeSelector</code> to force scheduling to a single node has the downside of requiring multiple RCs for a single application and making that application less resilient to a node failure. The idea of a custom scheduler is nice but has the down... |
<p>Does kubernetes accessible via a REST API? I was looking over at the <a href="http://kubernetes.io/v1.0/docs/api.html" rel="noreferrer">Kubernetes API</a> page and it all looks very cryptic / incomplete. They talk about new versions but have not disclosed the API usage or docs anywhere. I just wanted to know if ther... | <p>You can see all the API calls kubectl is making by passing <code>--v=8</code> to any kubectl command</p>
|
<p>I follow this docs <code>https://cloud.google.com/container-engine/docs/tutorials/guestbook</code> to created a Guestbook on GCE. And everything works fine.</p>
<p>But when I try to access kube-ui. I am totally confused.</p>
<p>first</p>
<pre><code>≥ kubectl get svc ... | <p>Never mind, I got it</p>
<pre><code>gcloud container clusters describe CLUSTER-NAME
</code></pre>
<p>contains username and password!</p>
|
<p>I run the kube-apiserver with my self-signed certificate:</p>
<pre><code>/opt/bin/kube-apiserver \
--etcd_servers=http://master:2379,http://slave1:2379,http://slave2:2379 \
--logtostderr=false \
--v=4 \
--client-ca-file=/home/kubernetes/ssl/ca.crt \
--service-cluster-ip-range=192.168.3.0/24 \
--tls-cert-file=/home/... | <p>TL;DR. You can comment out "certificate-authority-data:" key to get it working.</p>
<hr />
<p>More info</p>
<p>There is an open issue (<a href="https://github.com/kubernetes/kubernetes/issues/13830" rel="nofollow noreferrer">https://github.com/kubernetes/kubernetes/issues/13830</a>) with the behavior of t... |
<p>Trying to use Cinder volumens on OpenStack as persistent volumes for my pods. As soon as I configure the cloudprovider and restart the kubelet, the kubelet fails to get its external ID from the cloud provider.</p>
<p>The OpenStack API is reachable via https using a comodo certificate. the comodo-ca-bundle is instal... | <p>Kubelet is able to reach Openstack, however it is failing to find this node in the list of servers, in this tenant, and in this region.
<code>Oct 01 07:40:27 [4196]: I1001 07:40:27.133478 4196 openstack.go:201] Found 8 compute flavors
Oct 01 07:40:27 [4196]: E1001 07:40:27.158908 4196 kubelet.go:846] Unable to... |
<p>Currently services support multiple ports from a single selector, that maps onto pods of single type. This service/ports in turn can be exposed externally through 'type:LoadBalancer".</p>
<p>For a given subsystem like Spark - there are 3 pod types - master, worker, driver with each exposing a set of management ui p... | <blockquote>
<p>Is there anyway to combine all of these heterogeneous pod ports into a
single "Service" with a corresponding "LoadBalancer".</p>
</blockquote>
<p>Services are intended to represent a homogeneous set of pods. Requests to the service are load balanced across the pods that back the service. </p>
<p>I... |
<p>I am using WmWare Workstation running a Linux vm which runs the vagrant and kubernetes environment.</p>
<p>I have a problem using kubernetes with vagrant. Every time if I shutdown the kubernetes cluster with the kube-down.sh tool and restart with kube-up.sh, I cannot connect to the minions anymore! I think it has s... | <p>Each run of kube-up.sh is intended to generate a new cluster. As such, it will create new credentials for the cluster and any existing nodes are not expected to continue to work with the new master components. </p>
|
<p>Using GKE. I declared a disk I use as persistent volume.</p>
<p>When the pod which uses the volume crashed and was re-started on a different node, the disk was still attached / mounted to the node it was mounted on before. </p>
<p>How comes the volume is not unmounted by the RC?</p>
<p>Then the pod fails and ther... | <p>This is a known issue. See <a href="https://github.com/kubernetes/kubernetes/issues/14642" rel="nofollow">https://github.com/kubernetes/kubernetes/issues/14642</a></p>
<p>We're working on a fix: See <a href="https://github.com/kubernetes/kubernetes/issues/15524" rel="nofollow">https://github.com/kubernetes/kubernet... |
<p>We are creating a new version of payment gateway processor and We want to use docker container with kubernetes but we are worried if Kubernetes and docker container follow the PCI DSS requirements.</p>
<p>We don't find anything clear in PCI DSS specifications. </p>
| <p>Re-iterating Tim's comment above: As far as I know nobody has implemented a fully PCI-compliant kubernetes install yet (they might have done and not told us). I don't know of anything specific to Docker or Kubernetes that would prevent you from getting your deployment certified. </p>
|
<p>I'm looking for a pattern that allows to share volumes between two containers running on the same pod in Kubernetes.</p>
<p>My use case is:
I have a Ruby on Rails application running inside a docker container.
The docker image contains static assets in <code>/app/<app-name>/public</code> directory, and I need... | <p><strong>[update-2016-8]</strong> In latest Kubernetes release, you can use a very nice feature named <code>init-container</code> to replace the <code>postStart</code> part in my answer below, which will make sure the container order.</p>
<pre><code>apiVersion: v1
kind: Pod
metadata:
name: javaweb-2
spec:
initCo... |
<p>We are trying a test setup with Kubernetes version 1.0.6 on AWS. </p>
<p>This setup involves pods for Cassandra (2-nodes), Spark (master, 2-workers, driver), RabbitMQ(1-node). Some the pods this setup die after a day or so</p>
<p>Is there way to get logs from Kubernetes on how/why they died?</p>
<p>When you try t... | <p><code>kubectl describe ${POD_NAME}</code> or <code>kubectl logs ${POD_NAME} ${CONTAINER_NAME}</code> should give you more information to debug.</p>
<p>Please also see <a href="https://github.com/kubernetes/kubernetes/blob/master/docs/user-guide/application-troubleshooting.md#debugging-pods" rel="nofollow">https://g... |
<p>I have a 3 node coros kubernetes cluster up and running.</p>
<p>I want to use persitentvolumes(pv) from a standalone NFS Server.</p>
<p>nfs.yaml</p>
<pre><code>apiVersion: v1
kind: PersistentVolume
metadata:
name: kube1
spec:
capacity:
storage: 9.5G
accessModes:
- ReadWriteMany
nfs:
path: /mnt... | <p>As far as I've seen, that's the way it should work. The claim is for the entire volume. The part that confused me at first as well, was the resources.requests.storage value is only a minimum value that claim requires. I use this with Ceph, and when Pods bind to the block device, they take the whole volume.</p>
|
<p>Is it possible to pass the "--volume-driver" with in kubernetes' yml file?</p>
<p>Ex. Using Docker I can perform the following</p>
<p>docker run --volume-driver rbd -v image:/mountpoint ubuntu</p>
<p>Thanks</p>
| <p>Kubernetes does support several volume types, including rbd, as you mention in your example. When you create a pod, you can specify what volumes and their types you want in the yaml file. Documentation on volumes is here: <a href="http://kubernetes.io/v1.0/docs/user-guide/volumes.html#rbd" rel="nofollow">http://kub... |
<p>I'm a bit disturbed on how to secure the kubernetes API for call and access, also Kube-ui is available to everybody.
How can I set credential to secure all the services ?</p>
<p>Thank you</p>
| <p>The Kubernetes API supports multiple forms of <a href="http://kubernetes.io/v1.0/docs/admin/authentication.html">authentication</a>: http basic auth, bearer token, client certificates. When launching the apiserver, you can enable / disable each of these authentication methods with command line flags. </p>
<p>You sh... |
<p>Stuck on how to make it run. I followed everything on the <a href="http://kubernetes.io/v1.0/examples/meteor/README.html" rel="nofollow">http://kubernetes.io/v1.0/examples/meteor/README.html</a></p>
<p>I was able to build the image and push it to the gcloud. Now the problem is how to run it.</p>
<p>I accessed the ... | <p>Did you open up port 80 for meteor?</p>
<pre><code>gcloud compute firewall-rules create meteor-80 --allow=tcp:80 --target-tags kubernetes-minion
</code></pre>
|
<p>I tried looking for a Jenkins plugin (like AWS codeDeploy) so that I could deploy my application to a Kubernetes cluster. So far, I have been successful at pushing it to a Docker registry and adding some command line build steps to deploy to Kubernetes.
Looking at the CloudBees announcement <a href="http://blog.clou... | <p>The <a href="https://github.com/jenkinsci/kubernetes-plugin" rel="nofollow">Jenkins Kubernetes plugin</a> is (so far) only to run slaves dynamically in a Kubernetes cluster</p>
<p>There's not a lot about deploying from Jenkins to Kubernetes, maybe this post <a href="https://medium.com/fabric8-io/create-and-explore-... |
<p>I was able to expose port 80 before, just last month, using kubernetes and google containers.<br>
But now simple service example like this doesn't work anymore:</p>
<pre><code>{
"kind":"Service",
"apiVersion":"v1",
"metadata":{
"name":"check",
"labels":{
"app":"check"
... | <p>I guess your pods are exposing port 8080? then you are missing <code>targetPort</code></p>
<pre><code> "ports": [
{
"port":80,
"targetPort": "8080",
"name":"check-server"
}
</code></pre>
|
<p>We are running a workload against a cluster hosting 2 instances of a small (3 container) pod. Accessing the pod using a service w/nodeport. If we stop a pod and rc starts a new one, our constant (low volume) workload has numerous failures (Rational Perf Tester, http test hitting the service on the master ... but l... | <p>This is precisely what the <code>readinessProbe</code> option is :)</p>
<p>It's documented more <a href="http://kubernetes.io/v1.0/docs/user-guide/pod-states.html#container-probes" rel="nofollow">here</a> and <a href="http://kubernetes.io/v1.0/docs/user-guide/production-pods.html#liveness-and-readiness-probes-aka-h... |
<p>I'm trying to enable the skyDNS addon for my kubernetes cluster. I'm behind a corporate proxy, and it seems to be unable to talk to gcr.io. The following errors show up in the logs:</p>
<pre><code>Oct 20 13:55:46 atomic01.localdomain kubelet[112453]: W1020 13:55:46.143403 112453 manager.go:1569] Failed to pull ima... | <p>What config file are you using to launch the DNS add-on? You should be able to just edit it (or make a copy of <a href="https://github.com/kubernetes/kubernetes/blob/master/cluster/addons/dns/skydns-rc.yaml.in" rel="nofollow">this one</a>) and point it at a different registry. </p>
|
<p>I'm having an issue whereby cronjob in kubernetes doesnt seem to work.
Below is the test Dockerfile used</p>
<pre><code>FROM debian:jessie
RUN apt-get update
RUN apt-get -y install --no-install-recommends cron
RUN echo 'PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin' | crontab
RUN echo '0-59/2... | <p>Somehow I got it working by switching the Dockerfile around</p>
<p>Dockerfile</p>
<pre><code>FROM debian:jessie
RUN apt-get update
RUN apt-get -y install --no-install-recommends cron
COPY . /src
WORKDIR /src
RUN cp run.sh /run.sh \
&& chmod a+x /run.sh \
&& touch /var/log/cron.log
CMD [... |
<p>A little bit of background: I have a Go service that uses gRPC to communicate with client apps. gRPC uses HTTP2, so I can't use Google App Engine or the Google Cloud HTTP Load Balancer. I need raw TCP load balancing from the internet to my Go application.</p>
<p>I went through the GKE tutorials and read the various... | <p>This is not supported in kubernetes v1.0.x but in v1.1.x it will be available as <code>service.spec.loadBalancerIP</code>. As long as you actually own that IP we will use it.</p>
|
<p>I have a working kubernetes cluster with the elasticsearch up and running returning a 200. I am trying to install the HQ plugin. So i log into the node running the es-client, and attach to the docker container. When i execute the command</p>
<pre><code>/ # /elasticsearch/bin/plugin -install royrusso/elasticsearch-... | <p>Attach to the container</p>
<pre><code>docker exec -it 9f13966b1201 /bin/sh
</code></pre>
<p>Export the DISCOVERY_SERVICE</p>
<pre><code>export DISCOVERY_SERVICE=${DISCOVERY_SERVICE:-elasticsearch-discovery}
</code></pre>
<p>Install the Plugin</p>
<pre><code>/elasticsearch/bin/plugin -install royrusso/elastics... |
<p>Docker allows execution of commands as other user with <code>docker exec -u</code>, when <code>USER something</code> in used in Dockerfile.
It is helpful to enter into superuser mode to debug issues, when you are running you <code>CMD</code> as system user in Dockerfile.</p>
<p>How to execute commands on Kubernetes... | <p>You can check the spec schema to see what you can add in a pod or replication controller or whatever: <a href="https://cloud.google.com/container-engine/docs/spec-schema" rel="noreferrer">https://cloud.google.com/container-engine/docs/spec-schema</a></p>
<p>You have runAsUser for what you want:</p>
<pre><code>apiV... |
<p>I'm setting up rethinkdb cluster inside kubernetes, but it doesn't work as expected for high availability requirement. Because when a pod is down, kubernetes will creates another pod, which runs another container of the same image, old mounted data (which is already persisted on host disk) will be erased and the new... | <p>That's how Kubernetes works, and other solution works probably same way. When a machine is dead, the container on it will be rescheduled to run on another machine. That other machine has no state of container. Event when it is the same machine, the container on it is created as a new one instead of restarting the ... |
<p>For instance can I have following yaml to produce a pod with multiple containers:</p>
<pre><code>apiVersion: v1
kind: Pod
metadata:
name: lampapp
labels:
app: app
spec:
containers:
- name: lampdb
image: mysql_test
- name: app
image: php-app-db-url-env
env:
- name: DB_URL
value: 127.... | <p>Yes, you can add multiple container with same image.</p>
<p><strong>The containers object must contain:</strong></p>
<ol>
<li><strong>name:</strong> Name of the container. It must be a <em>DNS_LABEL</em> and be <code>unique</code> within the pod. Cannot be updated.</li>
<li><strong>image:</strong> Docker image nam... |
<p>Kubernetes verison: 1.02 </p>
<p>PATCH /api/v1/namespaces/default/replicationcontrollers/test </p>
<pre><code>body
{"spec":
{"replicas": 3}
}
response
'{
"kind": "Status",
"apiVersion": "v1",
"metadata": {},
"status": "Failure",
"message": "the server responded with the status code 415 but d... | <p>For PATCH to work you need to send one of the <a href="http://kubernetes.io/v1.0/docs/devel/api-conventions.html#patch-operations" rel="nofollow noreferrer">accepted content-type header values</a>.</p>
<p>Your example uses a <a href="https://www.rfc-editor.org/rfc/rfc7386" rel="nofollow noreferrer">merge patch</a>, ... |
<p>I am trying to figure out how to update a node's pod capacity. I have a simple cluster setup using the Vagrant/VM environment outlined in the documentation. I have attempted to patch the node's pod capacity using kubectl doing the following:</p>
<p>Sending just JSON needed for patch via:</p>
<pre><code>kubectl pat... | <p>NodeStatus is a subresource that is periodically updated by the node (kubelet) itself, and the capacity is calculated based on available resources (cpu, mem, etc) on the node. Updating the Node object does not update the status.</p>
<p>If you want to set a maximum capacity of a node, you can pass a <a href="https:/... |
<p>I'm having an issue where a container I'd like to run doesn't appear to be getting started on my cluster.</p>
<p>I've tried searching around for possible solutions, but there's a surprising lack of information out there to assist with this issue or anything of it's nature.</p>
<p>Here's the most I could gather:</p... | <p>You only have one node in your cluster and its status in <code>NotReady</code>. So you won't be able to schedule any pods. You can try to determine why your node isn't ready by looking in <code>/var/log/kubelet.log</code>. You can also add new nodes to your cluster (scale the cluster size up to 2) or delete the node... |
<p>I'm using Kubernetes v1.0.6 on AWS that has been deployed using <code>kube-up.sh</code>.<br>
Cluster is using <code>kube-dns</code>.</p>
<pre><code>$ kubectl get svc kube-dns --namespace=kube-system
NAME LABELS SELECTOR IP(S) ... | <p>The <a href="https://github.com/kubernetes/kubernetes/blob/b9cfab87e33ea649bdd13a1bd243c502d76e5d22/cluster/addons/dns/README.md#inheriting-dns-from-the-node" rel="nofollow">DNS addon README</a> has some details on this. Basically, the pod will inherit the <code>resolv.conf</code> setting of the node it is running o... |
<p>i´ve created a cluster on google cloud platform consisting of 3 g1-small instances and have not yet added any pod / service / etc. Still, when I log on to the Kubernetes UI, all three instances show a very high memory consumption of ~ 1.3 GB. What is this memory used for? Or is it a problem with the kubernetes ui?</... | <p>kube-ui seems to be showing the total memory usage, as opposed to the memory working set. The former includes inactive pages which are not in use, so the memory would appear higher. To see the memory working set, you can try reaching other monitoring services such as monitoring-grafana (backed by heapster) or simply... |
<p>I have 4 nodes (<code>kubelets</code>) configured with a label <code>role=nginx</code></p>
<pre><code>master ~ # kubectl get node
NAME LABELS STATUS
10.1.141.34 kubernetes.io/hostname=10.1.141.34,role=nginx Ready
10.1.141.40 kubernetes.io/hostname=10.1.141.40,... | <p>Prior to DaemonSet being available, you can also specify that you pod uses a host port and set the number of replicas in your replication controller to something greater than your number of nodes. The host port constraint will allow only one pod per host. </p>
|
<p>We'd like to customise the fluentd config that comes out of the box with the kubernetes fluentd-elasticsearch addon. It seems however that there is no easy way of doing this with the current supplied Docker images.</p>
<p>The following file: <a href="https://github.com/kubernetes/kubernetes/blob/master/cluster/add... | <p>Unfortunately, I am not aware of any method to customize the config. You can either create your own image, open a feature request at <a href="http://issues.k8s.io" rel="nofollow">issues.k8s.io</a>, or even submit a PR to to enhance fluentd.</p>
|
<p>Followed this guide to starting a local-machine kubernetes cluster:
<a href="http://kubernetes.io/v1.0/docs/getting-started-guides/docker.html" rel="nofollow">http://kubernetes.io/v1.0/docs/getting-started-guides/docker.html</a></p>
<p>I've created various pods with .yaml files and everything works, I can access ng... | <p>I just ran through this (slightly out of date) doc. What I found is that it works if you replace the <code>hyperkube:v0.21.2</code> with <code>hyperkube:v1.0.7</code> in the 2 "docker run" lines, and replace <code>0.18.2</code> with <code>1.0.7</code> in the kubectl download URL.</p>
<p>I have offered a pull-reque... |
<p>I have a service in kubernetes that is exposed on port 80 via load balancer on AWS.
I also have a DNS configured to point on the load balancer host name.</p>
<p>I want to add another port to the service without replacing it, which also replaces the load balancer and its domain.</p>
<p>The only option I saw is to a... | <p>I'm not an expert with ELB, so I don't know if it is possible, but I'll talk about GCE and then assert that AWS should operate similarly.</p>
<p>In Kubernetes v1.0.x there is an unfortunate bug that releases your external load-balancer and recreates it when you update a Service. In Kubernetes v1.1 we have gone to ... |
<p>I'm trying to wrap my head around how kubernetes (k8s) utilises ports. Having read the API documentation as well as the available docs, I'm not sure how the port mapping and port flow works.</p>
<p>Let's say I have three containers with an externally hosted database, my k8s cluster is three on-prem CoreOS nodes, an... | <p>Thanks for the very detailed setup, but I still have some questions.</p>
<p>1) When you say "Container" {A,B,C} do you mean Pod? Or are A, B, C containers in the same Pod?</p>
<p>2) "Container B utilises incoming port 8081 to talk to Container A and C" - What do you mean that it uses an INcoming port to talk to o... |
<p>Is there any way to access the UI on the GKE service? </p>
<p>I tried following the information on <a href="https://github.com/kubernetes/kubernetes/blob/v1.0.6/docs/user-guide/ui.md" rel="nofollow">https://github.com/kubernetes/kubernetes/blob/v1.0.6/docs/user-guide/ui.md</a>
And got this</p>
<pre><code>Error: '... | <p>That error means that the master can't communicate with the nodes in your cluster. Have you deleted the instances from your cluster, or messed with the firewalls? There should be a firewall allowing access SSH to the nodes in the cluster from the master's IP address, and an entry in your project-wide metadata with t... |
<p>If possible I'd like setup a multi-zone Kubernetes cluster on GCE but when creating a new cluster from the web console I can only select a single zone:</p>
<p><a href="https://i.stack.imgur.com/gcMxg.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/gcMxg.png" alt="enter image description here"></a... | <p>Google Container Engine is a zonal service, which means that each cluster runs wholly within a single zone. </p>
<p>If you want to do this manually you can follow <a href="https://stackoverflow.com/questions/31302233/resize-instance-types-on-container-engine-cluster/31303169#31303169">these instructions</a> to crea... |
<p>I was hoping to follow this architecture:</p>
<pre><code> -> service 1
-> nginx -> service 2
-> service 3
</code></pre>
<p>The reason I want to use nginx (instead of the default kube services using kube-proxy) is that it has x-accel-redirects which is great for authentication. Norm... | <p>You might be interested in our new Ingress API and load-balancer controllers (beta in kubernetes v1.1) We have HAProxy support, but not nginx (yet).</p>
<p><a href="https://github.com/kubernetes/contrib/tree/master/service-loadbalancer" rel="nofollow">https://github.com/kubernetes/contrib/tree/master/service-loadb... |
<p>I've installed Kubernetes via Vagrant on OS X and everything seems to be working fine, but I'm unsure how kubectl is able to communicate with the master node despite being local to the workstation filesystem. </p>
<p>How is this implemented?</p>
| <p>kubectl has a configuration file that specifies the location of the Kubernetes apiserver and the client credentials to authenticate to the master. All of the commands issued by kubectl are over the HTTPS connection to the apiserver. </p>
<p>When you run the scripts to bring up a cluster, they typically generate thi... |
<p>TL;DR Kubernetes allows all containers to access all other containers on the entire cluster, this seems to greatly increase the security risks. How to mitigate?</p>
<p>Unlike <a href="https://www.docker.com/" rel="nofollow">Docker</a>, where one would usually only allow network connection between containers that ne... | <p>In the not-too-distant future we will introduce controls for network policy in Kubernetes. As of today that is not integrated, but several vendors (e.g. Weave, Calico) have policy engines that can work with Kubernetes.</p>
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.