在GKE上更改kubernetes主环境变量 [英] Change kubernetes master env variable on GKE

查看:86
本文介绍了在GKE上更改kubernetes主环境变量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用我在GKE上的Kubernetes集群启用Stackdriver日志记录.

I want to enable Stackdriver logging with my Kubernetes cluster on GKE.

在此声明: https://kubernetes.io/docs/user-指南/日志记录/堆栈驱动程序/

本文假设您已经创建了具有群集级别日志记录支持的Kubernetes群集,用于将日志发送到Stackdriver Logging.您可以通过在GKE中的创建群集"对话框中选中启用堆栈驱动程序日志记录"复选框,或在使用kube-up.sh手动启动群集时将KUBE_LOGGING_DESTINATION标志设置为gcp来实现此目的.

This article assumes that you have created a Kubernetes cluster with cluster-level logging support for sending logs to Stackdriver Logging. You can do this either by selecting the Enable Stackdriver Logging checkbox in the create cluster dialogue in GKE, or by setting the KUBE_LOGGING_DESTINATION flag to gcp when manually starting a cluster using kube-up.sh.

但是我的集群是在未启用此选项的情况下创建的.

But my cluster was created without this option enabled.

在集群运行时如何更改环境变量?

How do I change the environment variable while my cluster is running?

推荐答案

不幸的是,一旦运行,日志记录就不能在群集上启用/禁用.这是我们希望在不久的将来改变的事情,但是与此同时,最好的选择是删除并重新创建集群(对不起!).

Unfortunately, logging isn't a setting that can be enabled/disabled on a cluster once it is running. This is something that we hope to change in the near future, but in the mean time your best bet is to delete and recreate your cluster (sorry!).

这篇关于在GKE上更改kubernetes主环境变量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆