From dd163302042ba9df4089ab49eae01246bd6020f2 Mon Sep 17 00:00:00 2001 From: albert Date: Sun, 23 Jun 2024 20:23:35 +0900 Subject: [PATCH] Updates --- .forgejo/workflows/build-console-iso.yml | 59 ----------------- .forgejo/workflows/build-desktop-iso.yml | 50 -------------- .forgejo/workflows/build-linode-img.yml | 52 --------------- .forgejo/workflows/ssh-test.yml | 83 ------------------------ 4 files changed, 244 deletions(-) delete mode 100644 .forgejo/workflows/build-console-iso.yml delete mode 100644 .forgejo/workflows/build-desktop-iso.yml delete mode 100644 .forgejo/workflows/build-linode-img.yml delete mode 100644 .forgejo/workflows/ssh-test.yml diff --git a/.forgejo/workflows/build-console-iso.yml b/.forgejo/workflows/build-console-iso.yml deleted file mode 100644 index 91aa2b94..00000000 --- a/.forgejo/workflows/build-console-iso.yml +++ /dev/null @@ -1,59 +0,0 @@ -name: build-console-iso -run-name: ${{ github.actor }} - build-console-iso -on: - schedule: - - cron: '0 2 1,15 * *' - # “At 02:00 on day-of-month 1 and 15.” - -jobs: - build-console-iso: - runs-on: docker - container: - image: alpine:edge - steps: - - name: "Setup Runner" - run: | - apk update - apk add git nodejs nix --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing/ - - uses: actions/checkout@v3 - with: - sparse-checkout: | - .forgejo - home-manager - lib - nixos - flake.lock - flake.nix - shell.nix - - name: "Directory Structure" - run: | - ls ${{ github.workspace }}/* - - name: "Runner: Node Info" - run: | - id - uname -a - hostname - cat /etc/os-release - - name: "Nix Version" - run: | - nix --version - - name: "Nix build" - run: | - echo "Running Nix Build" - nix --extra-experimental-features "nix-command flakes" \ - build /workspace/albert/nix#imageConfigurations.nixos-iso-console - echo "Results:" - ls -lah result/iso/ - - - if: always() - run: rm -rf /.cache - - if: always() - run: rm -rf ${{ github.workspace }} - - if: failure() - uses: https://git.sysctl.io/actions/gotify-action@master - with: - gotify_api_base: '${{ secrets.GOTIFY_URL }}' - gotify_app_token: '${{ secrets.GOTIFY_TOKEN }}' - notification_title: '[ ${{ github.repository }}: ${{ github.workflow }} ] Build Failed' - notification_message: 'Your build has failed. Check Forgejo.' - name: "Send Notification" \ No newline at end of file diff --git a/.forgejo/workflows/build-desktop-iso.yml b/.forgejo/workflows/build-desktop-iso.yml deleted file mode 100644 index db3005b3..00000000 --- a/.forgejo/workflows/build-desktop-iso.yml +++ /dev/null @@ -1,50 +0,0 @@ -name: build-desktop-iso -run-name: ${{ github.actor }} - build-desktop-iso -on: - schedule: - - cron: '0 0 1,15 * *' - # “At 00:00 on day-of-month 1 and 15.” - -jobs: - build-desktop-iso: - runs-on: docker - container: - image: alpine:edge - steps: - - name: "Setup Runner" - run: | - apk update - apk add git nodejs nix --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing/ - - uses: actions/checkout@v3 - - name: "Directory Structure" - run: | - ls ${{ github.workspace }}/* - - name: "Runner: Node Info" - run: | - id - uname -a - hostname - cat /etc/os-release - - name: "Nix Version" - run: | - nix --version - - name: "Nix build" - run: | - echo "Running Nix Build" - nix --extra-experimental-features "nix-command flakes" \ - build /workspace/albert/nix#imageConfigurations.nixos-iso-desktop - echo "Results:" - ls -lah result/iso/ - - - if: always() - run: rm -rf /.cache - - if: always() - run: rm -rf ${{ github.workspace }} - - if: failure() - uses: https://git.sysctl.io/actions/gotify-action@master - with: - gotify_api_base: '${{ secrets.GOTIFY_URL }}' - gotify_app_token: '${{ secrets.GOTIFY_TOKEN }}' - notification_title: '[ ${{ github.repository }}: ${{ github.workflow }} ] Build Failed' - notification_message: 'Your build has failed. Check Forgejo.' - name: "Send Notification" \ No newline at end of file diff --git a/.forgejo/workflows/build-linode-img.yml b/.forgejo/workflows/build-linode-img.yml deleted file mode 100644 index b2dcaa3a..00000000 --- a/.forgejo/workflows/build-linode-img.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: build-linode-img -run-name: ${{ github.actor }} - build-linode-img -on: - schedule: - - cron: '0 4 1,15 * *' - # “At 02:00 on day-of-month 1 and 15.” - -jobs: - build-linode-img: - runs-on: docker - container: - image: alpine:edge - steps: - - name: "Setup Runner" - run: | - apk update - apk add git nodejs nix --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing/ - - uses: actions/checkout@v3 - - name: "Directory Structure" - run: | - ls ${{ github.workspace }}/* - - name: "Runner: Node Info" - run: | - id - uname -a - hostname - cat /etc/os-release - - name: "Nix Version" - run: | - nix --version - - name: "Nix build" - run: | - echo "Running Nix Build" - nix --extra-experimental-features "nix-command flakes" \ - build ${{ github.workspace }}/#imageConfigurations.nixos-linode-img - - name: "Results" - run: | - echo "Results:" - ls -lah result/* - - - if: always() - run: rm -rf /.cache - - if: always() - run: rm -rf ${{ github.workspace }} - - if: failure() - uses: https://git.sysctl.io/actions/gotify-action@master - with: - gotify_api_base: '${{ secrets.GOTIFY_URL }}' - gotify_app_token: '${{ secrets.GOTIFY_TOKEN }}' - notification_title: '[ ${{ github.repository }}: ${{ github.workflow }} ] Build Failed' - notification_message: 'Your build has failed. Check Forgejo.' - name: "Send Notification" \ No newline at end of file diff --git a/.forgejo/workflows/ssh-test.yml b/.forgejo/workflows/ssh-test.yml deleted file mode 100644 index ac965d82..00000000 --- a/.forgejo/workflows/ssh-test.yml +++ /dev/null @@ -1,83 +0,0 @@ -name: ssh-test -run-name: ${{ github.actor }} - ssh-test -on: - push: - branches: - - main - -jobs: - ssh-test: - runs-on: alpine - container: - image: alpine:edge - options: --mount type=bind,src=/dev/net/tun,dst=/dev/net/tun --privileged - steps: - - name: "Runner: Info" - run: | - set -x - pwd - ls -lah - id - uname -a - hostname - cat /etc/os-release - whoami - id - cat /etc/resolv.conf - - - name: "Setup: Runner" - run: | - apk update - apk add git nodejs nix openssh-client qemu tailscale sudo --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing/ - - - name: "Setup: SSH" - run: | - mkdir /root/.ssh - echo "${{ secrets.SSH_PUBLIC_KEY }}" > /root/.ssh/id_ed25519.pub - echo "${{ secrets.SSH_PRIVATE_KEY }}" > /root/.ssh/id_ed25519 - chmod 700 /root/.ssh - chmod 600 /root/.ssh/id_ed25519 - chmod 644 /root/.ssh/id_ed25519.pub - echo "Public Key: " - cat /root/.ssh/id_ed25519.pub - - - name: "Setup: Headscale" - run: | - echo "tailscaled --cleanup" - sudo tailscaled --cleanup - echo "" - echo "tailscaled --state=mem 2> ~/tailscaled.log &" - sudo tailscaled --state=mem: 2> ~/tailscaled.log & - echo "" - echo "tailscale up" - sudo tailscale up \ - --login-server=https://headscale.sysctl.io \ - --accept-routes \ - --accept-dns \ - --authkey ${{ secrets.TAILSCALE_KEY }} \ - --hostname forgejo-runner \ - --advertise-tags "tag:forgejo,tag:container,tag:ephemeral" - sudo tailscale status - sudo tailscale netcheck - - - uses: actions/checkout@v3 - - name: "Directory Structure" - run: | - ls ${{ github.workspace }}/* - - - name: "Nix Version" - run: | - nix --version - - - if: always() - uses: https://git.sysctl.io/actions/gotify-action@master - with: - gotify_api_base: '${{ secrets.GOTIFY_URL }}' - gotify_app_token: '${{ secrets.GOTIFY_TOKEN }}' - notification_title: '[ ${{ github.repository }}: ${{ github.workflow }} ] Build Complete' - notification_message: 'Your build has completed.' - name: "Send Notification" - - if: always() - run: rm -rf /.cache - - if: always() - run: rm -rf ${{ github.worksspace }} \ No newline at end of file