Add Docker Hub description update step to CI workflow
This commit is contained in:
@@ -41,3 +41,19 @@ jobs:
|
||||
tags: |
|
||||
${{ vars.DOCKERHUB_USERNAME }}/opencode-devbox:${{ steps.version.outputs.version }}
|
||||
${{ vars.DOCKERHUB_USERNAME }}/opencode-devbox:latest
|
||||
|
||||
- name: Update Docker Hub description
|
||||
run: |
|
||||
TOKEN=$(curl -s -X POST https://hub.docker.com/v2/users/login/ \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{"username":"${{ vars.DOCKERHUB_USERNAME }}","password":"${{ secrets.DOCKERHUB_TOKEN }}"}' \
|
||||
| jq -r .token)
|
||||
jq -n \
|
||||
--arg full "$(cat DOCKER_HUB.md)" \
|
||||
--arg short "Portable AI dev environment for opencode. Debian-based with git, Node.js, AWS CLI, and SSH support." \
|
||||
'{"full_description": $full, "description": $short}' | \
|
||||
curl -s -o /dev/null -w "%{http_code}" -X PATCH \
|
||||
"https://hub.docker.com/v2/repositories/${{ vars.DOCKERHUB_USERNAME }}/opencode-devbox/" \
|
||||
-H "Authorization: JWT $TOKEN" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d @-
|
||||
|
||||
Reference in New Issue
Block a user