fix(ci-cd): use secrets for G_CLONE_URL instead of env variable

Replace hardcoded G_CLONE_URL references with GitHub secrets to
prevent exposing the repository URL in workflow logs and environment.
This commit is contained in:
db123-test
2026-05-04 09:25:46 +03:30
parent e29fd6d420
commit e326c4270c

View File

@@ -12,7 +12,7 @@ jobs:
runs-on: shell-ubuntu runs-on: shell-ubuntu
steps: steps:
- name: Checkout repo - name: Checkout repo
run: git clone "$G_CLONE_URL" . run: git clone "${{ secrets.G_CLONE_URL }}" .
- name: Download dependencies - name: Download dependencies
run: go mod download run: go mod download
@@ -37,7 +37,7 @@ jobs:
needs: lint-and-format needs: lint-and-format
steps: steps:
- name: Checkout repo - name: Checkout repo
run: git clone "$G_CLONE_URL" . run: git clone "${{ secrets.G_CLONE_URL }}" .
- name: Build for Linux amd64 - name: Build for Linux amd64
run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o auth-gate-linux-amd64 . run: CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o auth-gate-linux-amd64 .
@@ -61,7 +61,7 @@ jobs:
if: github.event_name == 'push' if: github.event_name == 'push'
steps: steps:
- name: Checkout repo - name: Checkout repo
run: git clone "$G_CLONE_URL" . run: git clone "${{ secrets.G_CLONE_URL }}" .
- name: Login to Gitea Registry - name: Login to Gitea Registry
run: echo "${{ secrets.G_TOKEN }}" | docker login git.yejayekhoob.com -u "${{ secrets.G_USERNAME }}" --password-stdin run: echo "${{ secrets.G_TOKEN }}" | docker login git.yejayekhoob.com -u "${{ secrets.G_USERNAME }}" --password-stdin