码迷,mamicode.com
首页 > 移动开发 > 详细

docker hub联通阿里云服务器部署

时间:2020-03-18 18:58:37      阅读:89      评论:0      收藏:0      [点我收藏+]

标签:docke   match   src   policy   temp   spec   target   type   云服务   

1. 在docker hub中配置

技术图片

2.在阿里云中指定对应的模版进行创建

apiVersion: v1
kind: Service
metadata:
  name: ivd-client
spec:
  selector:
    app: ivd-client
    tier: ivd-client
  ports:
  - protocol: "TCP"
    port: 80
    targetPort: 80
  type: LoadBalancer
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: ivd-client
spec:
  selector:
    matchLabels:
      app: ivd-client
      tier: ivd-client
      track: stable
  replicas: 1
  template:
    metadata:
      labels:
        app: ivd-client
        tier: ivd-client
        track: stable
    spec:
      containers:
      - name: ivd-client
        image: "{ 镜像名 }"
        imagePullPolicy: Always
        resources:
          requests:
            cpu: 50m
            memory: 30Mi
          limits:
            cpu: 100m
            memory: 100Mi
        ports:
        - containerPort: 80
      imagePullSecrets:
      - name: amwise

docker hub联通阿里云服务器部署

标签:docke   match   src   policy   temp   spec   target   type   云服务   

原文地址:https://www.cnblogs.com/barry-cbt/p/12518977.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!