dapr 项目编译

dapr runtime:v1.11.1

如果我们新增了自定义的组件或者修改了源码,这时需要重新将源码编译成一系列的可执行文件

第一步从github上拉取dapr项目

目录列表:

  • /opt/dapr/components-contrib:dapr 组件的目录
  • /opt/dapr/dapr:dapr runtime目录

执行编译指令:

#!/usr/bin/env bash
cd /opt/dapr/dapr
# 编译
make build
# 构建docker镜像
read -rp "输入版本号(v1.11.1-x):" NEW_DAPR_TAG
export DAPR_TAG=$NEW_DAPR_TAG
export DAPR_REGISTRY=<镜像仓库地址>
make docker-build
# 上传镜像
docker push $DAPR_REGISTRY/injector:$NEW_DAPR_TAG-linux-amd64
docker push $DAPR_REGISTRY/operator:$NEW_DAPR_TAG-linux-amd64
docker push $DAPR_REGISTRY/sentry:$NEW_DAPR_TAG-linux-amd64
docker push $DAPR_REGISTRY/placement:$NEW_DAPR_TAG-linux-amd64
docker push $DAPR_REGISTRY/daprd:$NEW_DAPR_TAG-linux-amd64
docker push $DAPR_REGISTRY/dapr:$NEW_DAPR_TAG-linux-amd64

同时修改配置(/opt/dapr/dapr/charts/dapr/values.yaml)

global:
  registry: <镜像仓库>
  tag: 'v1.11.1-0-linux-amd64'
  dnsSuffix: ".cluster.local"
  logAsJson: false
  imagePullPolicy: IfNotPresent
  imagePullSecrets: ""
  nodeSelector: {}
  tolerations: []
  rbac:
    namespaced: false
  ha:
    enabled: false
  prometheus:
    enabled: false
  mtls:
    enabled: false
    workloadCertTTL: 24h
    allowedClockSkew: 15m
  daprControlPlaneOs: linux
  labels: {}
  k8sLabels:
    app.kubernetes.io/name: "{{ .Release.Name }}"
    app.kubernetes.io/version: "{{ .Values.global.tag }}"
    app.kubernetes.io/part-of: "dapr"
    app.kubernetes.io/managed-by: "helm"
    app.kubernetes.io/component: "{{ .Values.component }}" # Should be set in each subchart

  issuerFilenames: {}
  argoRolloutServiceReconciler:
    enabled: false
  actors:
    enabled: false
  operator:
    watchdogCanPatchPodLabels: false

更新dapr

cd /opt/dapr/dapr
helm upgrade dapr ./charts/dapr --namespace dapr --wait

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值