Update .gitea/workflows/publish.yaml
All checks were successful
Hugo Publish CI / build-and-deploy (push) Successful in 14s
All checks were successful
Hugo Publish CI / build-and-deploy (push) Successful in 14s
This commit is contained in:
@@ -37,13 +37,18 @@ jobs:
|
|||||||
COMMIT_URL="https://git.ericxliu.me/eric/ericxliu-me/commit/$SHORT_COMMIT"
|
COMMIT_URL="https://git.ericxliu.me/eric/ericxliu-me/commit/$SHORT_COMMIT"
|
||||||
find ./public -type f -exec sed -i "s|\[commit\]|<a href=\"$COMMIT_URL\">\[$SHORT_COMMIT\]</a>|g" {} +
|
find ./public -type f -exec sed -i "s|\[commit\]|<a href=\"$COMMIT_URL\">\[$SHORT_COMMIT\]</a>|g" {} +
|
||||||
|
|
||||||
- name: Deploy
|
- name: Publish
|
||||||
uses: peaceiris/actions-gh-pages@v4
|
uses: peaceiris/actions-gh-pages@v4
|
||||||
with:
|
with:
|
||||||
personal_token: ${{ secrets.GIT_PAGES_TOKEN }}
|
personal_token: ${{ secrets.GIT_PAGES_TOKEN }}
|
||||||
publish_dir: ./public
|
publish_dir: ./public
|
||||||
publish_branch: gitea-pages
|
publish_branch: gitea-pages
|
||||||
|
|
||||||
- name: Reload Kubernetes pods
|
- name: Deploy
|
||||||
run: |
|
run: |
|
||||||
curl -X DELETE https://10.10.0.10:6443/api/v1/namespaces/hugo/pods/ --header "Authorization: Bearer ${{ secrets.HUGO_K8S_TOKEN }}" --insecure
|
K8S_TOKEN="${{secrets.K8S_TOKEN}}"
|
||||||
|
echo "K8S_TOKEN length: $(echo "$K8S_TOKEN" | wc -c)"
|
||||||
|
echo "K8S_TOKEN starts with: $(echo "$K8S_TOKEN" | head -c 20)..."
|
||||||
|
curl -X DELETE "https://10.10.0.10:6443/api/v1/namespaces/hugo/pods?labelSelector=app.kubernetes.io/name=hugo" \
|
||||||
|
--header "Authorization: Bearer $K8S_TOKEN" \
|
||||||
|
--insecure --fail-with-body --show-error --verbose
|
||||||
|
|||||||
Reference in New Issue
Block a user