name: Upload hello.txt to S3 on: push: branches: - main jobs: upload: runs-on: ubuntu-latest container: image: archlinux/archlinux:base-devel privileged: true steps: - name: Install Node.js run: pacman -Syu --noconfirm nodejs - name: Create hello.txt run: echo "Hello, Forgejo CI!" > hello.txt - name: Install MinIO Client (mc) run: | curl -O https://dl.min.io/client/mc/release/linux-amd64/mc chmod +x mc mv mc /usr/local/bin/ - name: Configure MinIO Client run: | mc alias set myminio $S3_ENDPOINT $S3_ACCESS_KEY $S3_SECRET_KEY - name: Upload file to S3 run: | mc cp hello.txt myminio/$S3_BUCKET_NAME/hello.txt env: S3_ENDPOINT: ${{ secrets.S3_ENDPOINT }} S3_ACCESS_KEY: ${{ secrets.S3_ACCESS_KEY }} S3_SECRET_KEY: ${{ secrets.S3_SECRET_KEY }} S3_BUCKET_NAME: ${{ secrets.S3_BUCKET_NAME }}