.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
配置管理-ConfigaMap和Secret
认识ConfigMap和Secret
创建ConfigMap和Secret的方式
以配置文件形式挂载ConfigMap和Secret
以环境变量形式挂载ConfigMap和Secret
更改挂载文件的名称和权
限解决挂载覆盖目录的问题
Secret管理域名证书
Secret管理镜像仓库密钥
Secret和ConfigMap配置只读
Secret和ConfigMap备份还原
Secret和ConfigMap使用注意事项 ...
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
一、什么是Ingress在 Kubernetes(K8s)环境中,Ingress 是一种 API 对象,用于管理集群内部服务(通常是 HTTP 服务)的外部访问,它提供了一种灵活的方式来定义和管理基于 HTTP/HTTPS 的路由规则,允许外部流量通过配置的规则访问 Kubernetes 集群中的服务。为集群中的服务提供了一个统一的入口,可以提供负载均衡、SSL终止和基于名称(域名)的虚拟主机,应用的灰度发布等功能。
Ingress 本身不直接处理流量,而是依赖于 In ...
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
第十七章、云原生监控Prometheus入门17.1什么是PrometheusPrometheus 是一个开源的系统监控和告警工具包。它最初是由 SoundCloud 开发的,目前已经成为云原生计算基金会(CNCF)的第二个毕业项目(仅次于 Kubernetes)。
主要特点包括:
多维度数据模型
时间序列数据由指标名称和键值对标签组成
支持灵活的查询语言 PromQL
数据收集
通过 HTTP 协议采用 pull 模型拉取数据
支持 push 网关来接收短期任务的数 ...
Docker
未读
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
从dockerhub拉取镜像该教程解决的是大陆用户无法从dockerhub拉取镜像的问题
使用Github Action将国外的Docker镜像转存到阿里云私有仓库,供国内服务器使用,免费易用
方案一:利用Github和阿里云拉取1. 准备工作:
登录阿里云,找到容器镜像服务,创建一个个人版实例。(第一次使用的话,会让设置访问密码。记住,后面会用)
找到仓库管理-命名空间,新建一个命名空间且设置为公开
不要创建镜像仓库,回到访问凭证
123sudo docke ...
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
1.持久化存储1.1Volumes介绍官方介绍:https://kubernetes.io/zh-cn/docs/concepts/storage/volumes/
Volumes是Kubernetes中的一个抽象概念,本质上是一个可以被Pod中容器访问的目录。它解决了容器中文件系统的临时性问题,使数据可以在容器重启后依然保持。
Volumes主要有以下几个用途:
数据持久化:保证容器重启后数据不丢失。
容器间数据共享:同一Pod中的多个容器可以访问同一个Volume。
扩展容器存储 ...
pod控制器
未读
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
1.kubernetes调度基础1.1replication controller和replicaset(了解即可)Replication Controller(复制控制器,RC)和 ReplicaSet(复制集,RS)是两种简单部署 Pod的方式。因为在生产环境中,主要使用更高级的 Deployment 等方式进行 Pod 的管理和部署,所以只需要简单了解即可。
1.1.1Replication ControllerReplication Controller(简称 RC)可确保 P ...
.video-container {
position: relative;
width: 100%;
padding-top: 56.25%; /* 16:9 aspect ratio (height/width = 9/16 * 100%) */
}
.video-container iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
1.创建pod使用 kubectl run 命令创建一个pod:
12345678# 基本命令格式kubectl run <pod-name> --image=<image-name> [options]# 示例:kubectl run nginx-pod --image=registry.cn-beijing.aliyuncs.com/k8s-liujunwei/nginx:1.24.0# nginx-pod 是创建pod的名字,所在命名空间唯一# --ima ...








