重新创建GCP kubernetes集群

时间:2018-04-18 09:57:55

标签: kubernetes google-cloud-platform google-kubernetes-engine

我想了解如何重新创建我的群集。有一个集群级别的设置来指定在其中创建的节点的IP范围,我想使用它,这样我就可以设置一个不错的防火墙规则。但是,一旦创建了集群,它看起来就无法更改。

我有许多命名空间,部署,服务,机密,持久卷和声明。如果我想将它们全部转移到新群集,我应该只在新群集上paintGLdef paintGL(self): glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT) gluOrtho2D(-self.zoomVal, +self.zoomVal, -self.zoomVal, +self.zoomVal) glLoadIdentity() glTranslated(*self.local_translate) glRotated(self.xRot / 16.0, 1.0, 0.0, 0.0) glRotated(self.yRot / 16.0, 0.0, 1.0, 0.0) glRotated(self.zRot / 16.0, 0.0, 0.0, 1.0) glScalef(*self.local_scale) genList = glGenLists(1) glNewList(genList, GL_COMPILE) for node in self.model: vertices = node.Vertices # list of vertices edges = node.Edges # list of edges face = node.Face # list of faces texcoords = node.TextureCoordinates # list of texture coordinates glPushAttrib(GL_ALL_ATTRIB_BITS) glPolygonMode(GL_FRONT, GL_FILL) glPixelStorei(GL_UNPACK_ALIGNMENT,1) glBindTexture(GL_TEXTURE_2D, node.TextureID) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR) # face and UV glBegin(GL_QUADS) self.qglColor(QColor(255,255,255)) for vertex in face: glVertex3fv(vertices[vertex]) glTexCoord2f(texcoords[vertex][0], texcoords[vertex][1]) glEnd() glPopAttrib() glEndList() glCallList(genList) kubectl get all --namespace=whatever --format=yaml吗?

如此粗暴的工作是否适用于映射到相同的负载均衡器/公共IP,持久量,秘密等?

1 个答案:

答案 0 :(得分:1)

正如您所看到的,整个集群的备份和迁移是一个非常讨论的问题,并且在Kubernetes github上仍然是一个未解决的问题:

因此,我不相信您发布的命令可能被视为解决方案或工作。我认为它会因集群相关的资源和IP不同而失败。此外,由于不支持这种使用,它将导致多个问题。

假设您更改了群集区域,如果磁盘无法连接到其他区域中的实例(或者可能迁移到其他云服务),如何移动PV?

更重要的是,我不会冒险删除我的作品以运行未记录或指示为最佳实践的命令。您可以在测试命名空间中尝试它,但我不建议更进一步。

您可以查看reshifterark,因为它们可能会满足您的需求。我从来没有对它们进行测试,但它们在线程中被提及,因此它们可能对您有意义。

我在我的一个测试集群中尝试了这种方法:

Error from server (Conflict): Operation cannot be fulfilled 
Error from server (Conflict): Operation cannot be fulfilled 
Error from server (Forbidden): [...]

老实说,我认为对于有限的资源子集,可能是有可能的(请注意,某些资源是正确创建的),但不能完全考虑迁移。