Files
ionosDnsClient/.gitea/workflows/weekly.yaml
T
renovate-bot 07e677325c chore(deps): update actions (#30)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [actions/setup-go](https://github.com/actions/setup-go) | action | minor | `v6.4.0` → `v6.5.0` |

---

### Release Notes

<details>
<summary>actions/setup-go (actions/setup-go)</summary>

### [`v6.5.0`](https://github.com/actions/setup-go/releases/tag/v6.5.0)

[Compare Source](https://github.com/actions/setup-go/compare/v6.4.0...v6.5.0)

#### What's Changed

##### Dependency update

- Upgrade actions dependencies by [@&#8203;priyagupta108](https://github.com/priyagupta108) with [@&#8203;Copilot](https://github.com/Copilot) in [#&#8203;744](https://github.com/actions/setup-go/pull/744)
- Upgrade [@&#8203;types/node](https://github.com/types/node) and typescript-eslint dependencies to resolve npm audit findings by [@&#8203;HarithaVattikuti](https://github.com/HarithaVattikuti) in [#&#8203;755](https://github.com/actions/setup-go/pull/755)
- Upgrade [@&#8203;actions/cache](https://github.com/actions/cache) to 5.1.0, log cache write denied by [@&#8203;jasongin](https://github.com/jasongin) in [#&#8203;758](https://github.com/actions/setup-go/pull/758)
- Upgrade version to 6.5.0 in package.json and package-lock.json by [@&#8203;HarithaVattikuti](https://github.com/HarithaVattikuti) in [#&#8203;762](https://github.com/actions/setup-go/pull/762)

#### New Contributors

- [@&#8203;priyagupta108](https://github.com/priyagupta108) with [@&#8203;Copilot](https://github.com/Copilot) made their first contribution in [#&#8203;744](https://github.com/actions/setup-go/pull/744)
- [@&#8203;jasongin](https://github.com/jasongin) made their first contribution in [#&#8203;758](https://github.com/actions/setup-go/pull/758)

**Full Changelog**: <https://github.com/actions/setup-go/compare/v6...v6.5.0>

</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - At any time (no schedule defined)
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](undefined) if that's undesired.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yMzMuNCIsInVwZGF0ZWRJblZlciI6IjQzLjIzMy40IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhY3Rpb24iLCJhdXRvbWVyZ2UiLCJkZXBzIl19-->

Reviewed-on: #30
Reviewed-by: t.behrendt <2+t.behrendt@noreply.localhost>
Co-authored-by: Renovate Bot <renovate@t00n.de>
Co-committed-by: Renovate Bot <renovate@t00n.de>
2026-07-08 09:10:07 +02:00

68 lines
2.3 KiB
YAML

name: Update Client
on:
schedule:
- cron: "@weekly"
workflow_dispatch:
jobs:
update-client:
runs-on:
- ubuntu-latest
- linux_amd64
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup Go
uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6.5.0
with:
go-version-file: 'go.mod'
- name: Install yq
run: |
sudo wget https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64 -O /usr/bin/yq
sudo chmod +x /usr/bin/yq
- name: Install openapi codegen
run: go install github.com/oapi-codegen/oapi-codegen/v2/cmd/oapi-codegen@v2.4.1
- name: Download Ionos DNS OpenAPI Spec
run: curl -sL https://developer.hosting.ionos.com/assets/kms-swagger-specs/dns.yaml -o openapi.yaml
- name: Compare OpenAPI Versions
id: version_check
run: |
NEW_VERSION=$(yq -r '.info.version' openapi.yaml)
if [ -f openapi_spec.yaml ]; then
OLD_VERSION=$(yq -r '.info.version' openapi_spec.yaml)
else
OLD_VERSION="0.0.0"
fi
echo "New Version: $NEW_VERSION"
echo "Old Version: $OLD_VERSION"
if [ "$NEW_VERSION" != "$OLD_VERSION" ]; then
echo "New version detected"
echo "NEW_VERSION=$NEW_VERSION" >> $GITHUB_ENV
else
echo "No new version detected"
exit 0
fi
- name: Generate OpenAPI Client
if: env.NEW_VERSION
run: |
rm -rf *.go
oapi-codegen --config cfg.yaml openapi.yaml
go mod tidy
- name: Update Local OpenAPI Spec
if: env.NEW_VERSION
run: mv openapi.yaml openapi_spec.yaml
- name: Commit and Push Changes
if: env.NEW_VERSION
run: |
git config user.name "OpenAPI Bot"
git config user.email "t.behrendt@t00n.de"
git add .
git commit -m "Update OpenAPI client to version $NEW_VERSION"
git push
- name: Create Tag
if: env.NEW_VERSION
run: |
git tag -a "v$NEW_VERSION" -m "Update OpenAPI client to version $NEW_VERSION"
git push origin "v$NEW_VERSION"