Skip to content

Cleanup Test Account #50

Cleanup Test Account

Cleanup Test Account #50

Workflow file for this run

name: Cleanup Test Account
on:
schedule:
# This workflow runs once a week, on Wednesdays
- cron: '0 6 * * 3'
workflow_dispatch:
jobs:
all:
name: cleanup
runs-on: ubuntu-latest
env:
IONOS_USERNAME: ${{ secrets.IONOS_USERNAME }}
IONOS_PASSWORD: ${{ secrets.IONOS_PASSWORD }}
IONOSCTL_VERSION: '6.2.0'
steps:
- name: Checking out crossplane provider
uses: actions/checkout@v4
with:
submodules: true
- name: Setup ionosctl
run: |
curl -sL https://github.com/ionos-cloud/ionosctl/releases/download/v${{ env.IONOSCTL_VERSION }}/ionosctl-${{ env.IONOSCTL_VERSION }}-linux-amd64.tar.gz | tar -xzv > /dev/null
mv ionosctl /usr/local/bin
ionosctl version
- name: Perform cleanup
working-directory: tools/scripts/cleanup
run: |
./delete-all-resources.sh &> output.log || true
cat output.log
# Upload the output as an artifact
- name: Create an artifact with the output logs file
uses: actions/upload-artifact@v4
if: always()
with:
name: cleanup-testaccount.log
path: |
./tools/scripts/cleanup/output.log