From ebe2c6e6291ec907142cee09cd2884211ba740af Mon Sep 17 00:00:00 2001 From: Janis Hutz Date: Fri, 3 Apr 2026 12:26:27 +0200 Subject: [PATCH] Add ftp and node build templates --- docker/build/docker-build.yml | 2 +- ftp/ftp-deploy.yml | 19 +++++++++++++++++++ node/advanced-build.yml | 22 ++++++++++++++++++++++ node/node-build.yml | 21 +++++++++++++++++++++ 4 files changed, 63 insertions(+), 1 deletion(-) create mode 100644 node/advanced-build.yml diff --git a/docker/build/docker-build.yml b/docker/build/docker-build.yml index c120639..cd21290 100644 --- a/docker/build/docker-build.yml +++ b/docker/build/docker-build.yml @@ -3,7 +3,7 @@ on: push jobs: build_container: - runs_on: ubuntu-latest + runs-on: ubuntu-latest steps: - name: Check out Git repository uses: actions/checkout@v6 diff --git a/ftp/ftp-deploy.yml b/ftp/ftp-deploy.yml index e69de29..13382ca 100644 --- a/ftp/ftp-deploy.yml +++ b/ftp/ftp-deploy.yml @@ -0,0 +1,19 @@ +on: push +name: Deploy website on push +jobs: + web-deploy: + name: Deploy + runs-on: ubuntu-latest + steps: + - name: Pull repo + uses: actions/checkout@v6 + with: + ref: build + - name: Push changes to webserver + uses: SamKirkland/FTP-Deploy-Action@v4.3.6 + with: + server: ${{ vars.FTP_URL }} + username: ${{ vars.FTP_USERNAME }} + password: ${{ secrets.FTP_PASSWORD }} + local-dir: dist/ + server-dir: website/ diff --git a/node/advanced-build.yml b/node/advanced-build.yml new file mode 100644 index 0000000..133db2e --- /dev/null +++ b/node/advanced-build.yml @@ -0,0 +1,22 @@ +# NOTE: This is still WIP +on: push +name: Run an npm build +jobs: + node-build: + name: Build + runs-on: ubuntu-latest + steps: + - name: Pull repo + uses: actions/checkout@v6 + - name: Run node build + uses: actions/node-action@main + with: + script: 'path/to/script' + - name: Upload built files + uses: actions/git-auto-commit-action@v7 + with: + branch: build + commit_message: "[skip ci] Run build on push" + commit_user_name: Node build runner [bot] + commit_user_email: actions@janishutz.com + commit_author: Node build runner [bot] diff --git a/node/node-build.yml b/node/node-build.yml index e69de29..4db122e 100644 --- a/node/node-build.yml +++ b/node/node-build.yml @@ -0,0 +1,21 @@ +on: push +name: Run a js build script +jobs: + node-build: + name: Build + runs-on: ubuntu-latest + steps: + - name: Pull repo + uses: actions/checkout@v6 + - name: Run node build + uses: actions/node-action@main + with: + script: 'path/to/script' + - name: Upload built files + uses: actions/git-auto-commit-action@v7 + with: + branch: build + commit_message: "[skip ci] Run build on push" + commit_user_name: Node build runner [bot] + commit_user_email: actions@janishutz.com + commit_author: Node build runner [bot]