摘要:heml version: helm3 harbor 需要装插件。 helm 需要安装helml-push 插件 helm plugin install https://github.com/chartmuseum/helm-push.git 或者 wget https://github.com/c
阅读全文
摘要:for i in `kubectl get deployments.apps | awk 'NR>1{print $1}'`;do kubectl get deployment $i -o jsonpath="{.spec.template.spec.containers[0].image}" ;
阅读全文
摘要:过滤噪音 for i in `ls $1`;do sed -i '/{}/d' $1\/$i sed -i '/^status:/,$d' $1\/$i sed -i '/managedFields:/,/manager: kube-controller-manager/d' $1\/$i sed
阅读全文
摘要:#!/usr/bin/env bash#Author: 原件#Data: 2020/12/30#Description: 清理无标签的镜像,保留每个镜像最新的5个tag。 docker system prune -f docker images | awk '{print $1}' | awk '{
阅读全文
摘要:解决办法 kubectl get -n kube-system -o yaml cm aws-auth | sed -E 's/[[:space:]]+\\n/\\n/g' | kubectl apply -f - 或者原文件 sed -i -E 's/[[:space:]]+\\n/\\n/g'
阅读全文
摘要:Error from server (NotFound): the server could not find the requested resource (get services http:heapster:) [root@init 1.8+]# kubectl logs -n kube-sy
阅读全文
摘要:#!/bin/bash for (( i=1;i<=9;i++)) do for ((j=1;j<=i;j++)) do let sum=i*j printf "%-8s" $j"x"$i=$sum done echo done #!/bin/bash for(( i=1 ;i<=9;i++ ))
阅读全文
摘要:i = 1while i <= 9: i += 1 j = 1 while j <= i-1: print("{}*{}=".format(j,i-1),j*(i-1),sep='',end=' ') j += 1 print('') for i in range(1,10): for y in r
阅读全文