diff --git a/charts/juno-node/Chart.yaml b/charts/juno-node/Chart.yaml index f043b956..5bd506dc 100644 --- a/charts/juno-node/Chart.yaml +++ b/charts/juno-node/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: juno-chart -version: 0.1.5 +version: 0.1.6 appVersion: "1" description: A Helm chart for deploying Juno service maintainers: diff --git a/charts/juno-node/templates/juno-data-backup-cronjob.yaml b/charts/juno-node/templates/juno-data-backup-cronjob.yaml index 22f91371..24afa5f4 100644 --- a/charts/juno-node/templates/juno-data-backup-cronjob.yaml +++ b/charts/juno-node/templates/juno-data-backup-cronjob.yaml @@ -146,10 +146,12 @@ data: - | apk add --no-cache curl && apk add --no-cache jq && - latestBlockNumber=$(curl --location '{{ .Values.backupJunoDataJob.junoFreeEndpoint }}/{{ .Values.backupJunoDataJob.network }}-juno' --header 'Content-Type: application/json' --data '{ "jsonrpc": "2.0","method": "starknet_blockNumber", "id": 1}' | jq '.result') && + latestBlockNumber=$(curl --location '{{ .Values.backupJunoDataJob.junoFreeEndpoint }}/{{ .Values.backupJunoDataJob.network }}-juno' --header 'Content-Type: application/json' --data '{ "jsonrpc": "2.0","method": "starknet_blockNumber", "id": 1}' | jq '.result') && echo "latestBlockNumber is $latestBlockNumber" && - mv /mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_{{ .Values.deployment.imagetag }}*.tar /mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_{{ .Values.deployment.imagetag }}_$latestBlockNumber.tar && - echo "/mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_{{ .Values.deployment.imagetag }}_$latestBlockNumber.tar" && + junoVersion=$(curl --location '{{ .Values.backupJunoDataJob.junoFreeEndpoint }}/{{ .Values.backupJunoDataJob.network }}-juno' --header 'Content-Type: application/json' --data '{ "jsonrpc": "2.0","method": "juno_version", "id": 1}' | jq -r '.result') && + echo "junoVersion is $junoVersion " && + mv /mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_*.tar /mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_${junoVersion}_${latestBlockNumber}.tar && + echo "/mnt/juno-tar-backup/juno_{{ .Values.backupJunoDataJob.network }}_${junoVersion}_${latestBlockNumber}.tar" && rclone copy /mnt/juno-tar-backup/*.tar R2:/{{ .Values.backupJunoDataJob.bucketName }}/{{ .Values.backupJunoDataJob.network }} volumeMounts: - name: {{ .Values.deployment.namespace }}-rclone-config diff --git a/charts/juno-node/values.yaml b/charts/juno-node/values.yaml index 32e90ade..dbd27528 100644 --- a/charts/juno-node/values.yaml +++ b/charts/juno-node/values.yaml @@ -243,7 +243,7 @@ secret: ### Back up juno data and upload to R2 cloud backupJunoDataJob: - enabled: true + enabled: false dataSource: "juno-sepolia-pv-ssd-juno-sepolia-0" backupSchedule: "0 3 * * *" cleanupSchedule: "0 10 * * *"