lucas2
3 years ago
10 changed files with 93 additions and 0 deletions
Binary file not shown.
@ -0,0 +1,22 @@ |
|||||
|
#!/bin/bash |
||||
|
images=( |
||||
|
k8s.gcr.io/pause:3.1=mirrorgooglecontainers/pause-amd64:3.1 |
||||
|
gcr.io/google_containers/defaultbackend-amd64:1.4=mirrorgooglecontainers/defaultbackend-amd64:1.4 |
||||
|
k8s.gcr.io/kubernetes-dashboard-amd64:v1.10.1=registry.cn-hangzhou.aliyuncs.com/google_containers/kubernetes-dashboard-amd64:v1.10.1 |
||||
|
k8s.gcr.io/heapster-influxdb-amd64:v1.3.3=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-influxdb-amd64:v1.3.3 |
||||
|
k8s.gcr.io/heapster-amd64:v1.5.2=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-amd64:v1.5.2 |
||||
|
k8s.gcr.io/heapster-grafana-amd64:v4.4.3=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-grafana-amd64:v4.4.3 |
||||
|
k8s.gcr.io/metrics-server-amd64:v0.3.6=registry.cn-hangzhou.aliyuncs.com/google_containers/metrics-server-amd64:v0.3.6 |
||||
|
) |
||||
|
|
||||
|
OIFS=$IFS; # ±£´æ¾ÉÖµ |
||||
|
|
||||
|
for image in ${images[@]};do |
||||
|
IFS='=' |
||||
|
set $image |
||||
|
docker pull $2 |
||||
|
docker tag $2 $1 |
||||
|
docker rmi $2 |
||||
|
docker save $1 > 1.tar && microk8s.ctr --namespace k8s.io image import 1.tar && rm 1.tar |
||||
|
IFS=$OIFS; # »¹Ô¾ÉÖµ |
||||
|
done |
@ -0,0 +1,21 @@ |
|||||
|
#!/bin/bash |
||||
|
images=( |
||||
|
k8s.gcr.io/pause:3.1=registry.cn-hangzhou.aliyuncs.com/google_containers/pause-amd64:3.1 |
||||
|
gcr.io/google_containers/defaultbackend:1.4=registry.cn-hangzhou.aliyuncs.com/google_containers/defaultbackend:1.4 |
||||
|
k8s.gcr.io/kubernetes-dashboard-amd64:v1.10.1=registry.cn-hangzhou.aliyuncs.com/google_containers/kubernetes-dashboard-amd64:v1.10.1 |
||||
|
k8s.gcr.io/heapster-influxdb-amd64:v1.3.3=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-influxdb-amd64:v1.3.3 |
||||
|
k8s.gcr.io/heapster-amd64:v1.5.2=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-amd64:v1.5.2 |
||||
|
k8s.gcr.io/heapster-grafana-amd64:v4.4.3=registry.cn-hangzhou.aliyuncs.com/google_containers/heapster-grafana-amd64:v4.4.3 |
||||
|
k8s.gcr.io/metrics-server/metrics-server:v0.5.0=registry.cn-hangzhou.aliyuncs.com/google_containers/metrics-server:v0.5.0 |
||||
|
) |
||||
|
|
||||
|
OIFS=$IFS; # ±£´æ¾ÉÖµ |
||||
|
|
||||
|
for image in ${images[@]};do |
||||
|
IFS='=' |
||||
|
set $image |
||||
|
microk8s.ctr image pull $2 |
||||
|
microk8s.ctr image tag $2 $1 |
||||
|
microk8s.ctr image rm $2 |
||||
|
IFS=$OIFS; # »¹Ô¾ÉÖµ |
||||
|
done |
File diff suppressed because one or more lines are too long
@ -0,0 +1 @@ |
|||||
|
eyJhbGciOiJSUzI1NiIsImtpZCI6IlUzdjFQQV9JUG11TVN1czVORXRnOFdrNldLM2FmRDhla3lpSkdraXl1NmcifQ.eyJpc3MiOiJrdWJlcm5ldGVzL3NlcnZpY2VhY2NvdW50Iiwia3ViZXJuZXRlcy5pby9zZXJ2aWNlYWNjb3VudC9uYW1lc3BhY2UiOiJrdWJlLXN5c3RlbSIsImt1YmVybmV0ZXMuaW8vc2VydmljZWFjY291bnQvc2VjcmV0Lm5hbWUiOiJkZWZhdWx0LXRva2VuLTZsbXJ3Iiwia3ViZXJuZXRlcy5pby9zZXJ2aWNlYWNjb3VudC9zZXJ2aWNlLWFjY291bnQubmFtZSI6ImRlZmF1bHQiLCJrdWJlcm5ldGVzLmlvL3NlcnZpY2VhY2NvdW50L3NlcnZpY2UtYWNjb3VudC51aWQiOiIzY2NjYTUwNi1kYTRiLTRiYzQtOTUzNC1kMWJkM2MyMDBmOGEiLCJzdWIiOiJzeXN0ZW06c2VydmljZWFjY291bnQ6a3ViZS1zeXN0ZW06ZGVmYXVsdCJ9.DYqvDNYB-8Mn80hzoPp1GI9DxuFlFnB85n7DiQsaeeW8Mp0U82oPjTPs99QPnPSLK4j9tiJjTeMIT75v0tVo4Z_-_QRs6vOM48CqND4UhaByDIW6NysRd3xtzdKuiYdTTfhaNSjo0A7GiFmtIlY35Xm0k-H04w9dNLMzVJg9HU0raDtMLmgmEFkbY4l-69bp45NBHkxiOzo6sljYzPaCvhVSZSaI30Zn0ZlRZW-YPbnts6f1qvt84PmmvLmqxcLkJVZ3FCzjAqvxZwu7qeRFvmVnCoU77RqjKi0_zAZgCrV7H3JRI2Lm8Pa-bgcJxpTpcMt6BB-E_XvBPWiXQRG9vA |
Binary file not shown.
File diff suppressed because one or more lines are too long
@ -0,0 +1,41 @@ |
|||||
|
apiVersion: apps/v1 #指定API版本标签 |
||||
|
kind: Deployment #定义资源的类型/角色,deployment为控制器,service,endpoints |
||||
|
metadata: #定义资源的元数据信息 |
||||
|
name: zj-deployment #定义资源的名称,在同一个namespace空间中必须是唯一的 |
||||
|
namespace: lk #默认default |
||||
|
labels: #定义资源标签 |
||||
|
app: zj-d |
||||
|
spec: |
||||
|
replicas: 2 #定义副本数量 |
||||
|
selector: #定义选择器 |
||||
|
matchLabels: #匹配上边的标签 |
||||
|
app: yamlzj-d #名称 |
||||
|
template: #定义模板 |
||||
|
metadata: |
||||
|
labels: |
||||
|
app: yamlzj-d |
||||
|
spec: |
||||
|
containers: #定义容器信息 |
||||
|
- name: yamlzj #容器名,与标签名要相同 |
||||
|
image: repository.anxinyun.cn/device/wytg:39.21-09-09 #容器使用的镜像以及版本 |
||||
|
imagePullPolicy: IfNotPresent #获取镜像的策略 Alawys表示下载镜像 IfNotPresent 表示优先使用本地镜像,否则下载镜像,Never表示仅使用本地镜像 |
||||
|
ports: |
||||
|
- containerPort: 6666 #定义容器的对外端口 |
||||
|
|
||||
|
--- |
||||
|
apiVersion: v1 #指定API版本标签 |
||||
|
kind: Service #定义资源的类型/角色,Deployment为控制器,Service,endpoints |
||||
|
metadata: #定义资源的元数据信息 |
||||
|
name: zj-service #定义资源的名称,在同一个namespace空间中必须是唯一的 |
||||
|
namespace: lk #默认default |
||||
|
labels: #定义资源标签 |
||||
|
app: zj-s |
||||
|
spec: |
||||
|
selector: |
||||
|
app: yamlzj-d #deployment标签 |
||||
|
type: NodePort |
||||
|
ports: |
||||
|
- protocol: TCP |
||||
|
port: 16666 # 集群内访问 |
||||
|
targetPort: 6666 #集群内 容器内端口 |
||||
|
nodePort: 30006 #集群外访问 范围30000-32767 |
Binary file not shown.
@ -0,0 +1,6 @@ |
|||||
|
{"message":"device_sync_person","data":{"personId":"100001","personCode":"100001","name":"张三","type":1,"idNum":"420381200010013857","icNum":"157342643","passNum":10,"passPeriod":"08:00~09:30,11:30~14:00,17:00~19:00","passMonday":true,"passTuesday":true,"passWednesday":true,"passThursday":true,"passFriday":true,"passSaturday":false,"passSunday":false,"startTime":"2019-01-01 00:00:00","expireTime":"2020-01-01 00:00:00","faces":[{"faceId":"3000004","image":"0aB1D98bsdDSBDDS23sdfisfs"}]}} |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
{"message":"snapshot_face","data":{"personId":"5907 d9b6bede435faf0828177e5bce07","faceId":"cf78bfabb138474c8b2b3a0077c9bec1","fullname":"韩梅梅","type":1,"idNum":"430726199801042312","icNum":"123475 ","snapPic":" /9j/2 wBDABQODxIPDRQSEBIXFRQYHjIhHhwcHj0sLiQy","score":92,"result":1,"snaptime":"2019-08-02 15:42:48"}} |
Loading…
Reference in new issue