From 08ac4bb33a5aa6fc4fba69e30417e8400e7a9325 Mon Sep 17 00:00:00 2001 From: cp-dharti-r Date: Mon, 22 Apr 2024 12:57:10 +0530 Subject: [PATCH] Use different method for set the value --- .github/workflows/deploy-backend-dev.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/deploy-backend-dev.yml b/.github/workflows/deploy-backend-dev.yml index bc8291d05..445a1d862 100644 --- a/.github/workflows/deploy-backend-dev.yml +++ b/.github/workflows/deploy-backend-dev.yml @@ -28,7 +28,7 @@ jobs: - name: Build backend and copy zip to S3 run: | secret_value="${{ secrets.RECAPTCHA_CONFIG_JSON_BASE64 }}" - sed -i "s|{{RECAPTCHA_CONFIG_JSON_BASE64}}|${secret_value}|g" utils/helper.go + awk -v val="${secret_value}" '{gsub(/{{RECAPTCHA_CONFIG_JSON_BASE64}}/, val)} 1' utils/helper.go > temp.go && mv temp.go utils/helper.go apt-get update && apt-get install -y zip GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o main main.go zip canopas_serverless_dev_${{ github.sha }}.zip main