From 896aa61076c14b2ccb85cc87cffc42a97707f8af Mon Sep 17 00:00:00 2001 From: Cliffano Subagio Date: Sun, 3 Nov 2024 16:31:59 +1100 Subject: [PATCH] Update all GitHub Actions workflows to latest generator template --- .github/actions/ci-action/Dockerfile | 3 --- .github/actions/ci-action/action.yaml | 4 ---- .github/actions/ci-action/entrypoint.sh | 2 -- .github/workflows/ci-workflow.yaml | 19 +++++++++++++++---- .github/workflows/publish-doc-workflow.yaml | 4 ++-- .../publish-javascript-workflow.yaml | 2 +- .../workflows/publish-python-workflow.yaml | 2 +- .github/workflows/publish-ruby-workflow.yaml | 2 +- .github/workflows/release-major-workflow.yaml | 19 ++++--------------- .github/workflows/release-minor-workflow.yaml | 19 ++++--------------- .github/workflows/release-patch-workflow.yaml | 17 +++-------------- CHANGELOG.md | 3 +++ 12 files changed, 34 insertions(+), 62 deletions(-) delete mode 100644 .github/actions/ci-action/Dockerfile delete mode 100644 .github/actions/ci-action/action.yaml delete mode 100755 .github/actions/ci-action/entrypoint.sh diff --git a/.github/actions/ci-action/Dockerfile b/.github/actions/ci-action/Dockerfile deleted file mode 100644 index 8b2df43..0000000 --- a/.github/actions/ci-action/Dockerfile +++ /dev/null @@ -1,3 +0,0 @@ -FROM cliffano/studio -COPY entrypoint.sh /entrypoint.sh -ENTRYPOINT ["/entrypoint.sh"] diff --git a/.github/actions/ci-action/action.yaml b/.github/actions/ci-action/action.yaml deleted file mode 100644 index b56597a..0000000 --- a/.github/actions/ci-action/action.yaml +++ /dev/null @@ -1,4 +0,0 @@ -name: 'CI' -runs: - using: 'docker' - image: 'Dockerfile' diff --git a/.github/actions/ci-action/entrypoint.sh b/.github/actions/ci-action/entrypoint.sh deleted file mode 100755 index 396f9f2..0000000 --- a/.github/actions/ci-action/entrypoint.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -make ci diff --git a/.github/workflows/ci-workflow.yaml b/.github/workflows/ci-workflow.yaml index 0f0ff92..d449468 100644 --- a/.github/workflows/ci-workflow.yaml +++ b/.github/workflows/ci-workflow.yaml @@ -3,14 +3,25 @@ name: CI on: [push, pull_request, workflow_dispatch] jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - uses: actions/setup-node@v4 with: - node-version: '20' - - uses: ./.github/actions/ci-action + node-version: '22' + - uses: iamsauravsharma/create-dotenv@v2.0.1 + with: + file-path: '/tmp/.env' + env: + GITHUB_ACTIONS: ${{ env.GITHUB_ACTIONS }} + - uses: cliffano/command-docker-action@v1.3.0 + with: + command: 'make ci' + image: cliffano/studio:2.5.0 + shell: bash + extra_path: /usr/local/go/bin:/usr/local/maven/bin:/usr/local/node/bin:/usr/local/openjdk-jdk/bin:/root/.cargo/bin:/root/go/bin + env_file: '/tmp/.env' - run: npm install -g gh-pages - - run: CACHE_DIR=/tmp gh-pages --dist doc/ --user "pakkunbot " --repo "https://cliffano:${{ secrets.OAPICF_GITHUB_TOKEN }}@github.com/oapicf/openapi-iplocation.git" + - run: CACHE_DIR=/tmp gh-pages --dist doc/ --user "pakkunbot " --repo "https://cliffano:${{ secrets.OAPICF_GITHUB_TOKEN }}@github.com/oapicf/openapi-okta-ip-ranges.git" diff --git a/.github/workflows/publish-doc-workflow.yaml b/.github/workflows/publish-doc-workflow.yaml index 93e7e3a..77630a4 100644 --- a/.github/workflows/publish-doc-workflow.yaml +++ b/.github/workflows/publish-doc-workflow.yaml @@ -5,7 +5,7 @@ name: Publish API Documentation - '*' jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: @@ -19,4 +19,4 @@ jobs: CACHE_DIR=/tmp gh-pages --dist doc/ --user "pakkunbot " --repo "https://cliffano:${{ secrets.OAPICF_GITHUB_TOKEN - }}@github.com/oapicf/openapi-iplocation.git" + }}@github.com/oapicf/openapi-okta-ip-ranges.git" diff --git a/.github/workflows/publish-javascript-workflow.yaml b/.github/workflows/publish-javascript-workflow.yaml index 4514f00..0522cfe 100644 --- a/.github/workflows/publish-javascript-workflow.yaml +++ b/.github/workflows/publish-javascript-workflow.yaml @@ -5,7 +5,7 @@ name: Publish JavaScript - '*' jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/publish-python-workflow.yaml b/.github/workflows/publish-python-workflow.yaml index f06aa13..09cce75 100644 --- a/.github/workflows/publish-python-workflow.yaml +++ b/.github/workflows/publish-python-workflow.yaml @@ -5,7 +5,7 @@ name: Publish Python - '*' jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/publish-ruby-workflow.yaml b/.github/workflows/publish-ruby-workflow.yaml index bf87a4e..16b1413 100644 --- a/.github/workflows/publish-ruby-workflow.yaml +++ b/.github/workflows/publish-ruby-workflow.yaml @@ -5,7 +5,7 @@ name: Publish Ruby - '*' jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - uses: actions/checkout@v4 with: diff --git a/.github/workflows/release-major-workflow.yaml b/.github/workflows/release-major-workflow.yaml index 97fd2b5..86fdc03 100644 --- a/.github/workflows/release-major-workflow.yaml +++ b/.github/workflows/release-major-workflow.yaml @@ -3,20 +3,9 @@ name: Release Major on: [workflow_dispatch] jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v4 + - uses: cliffano/release-action@v1.0.0 with: - token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - - uses: actions/setup-node@v4 - with: - node-version: '20' - - run: git config --global user.email "blah+pakkun@cliffano.com" - - run: git config --global user.name "pakkunbot" - - run: npm install -g rtk - - run: rtk release --release-increment-type major - - uses: ad-m/github-push-action@master - with: - tags: true - github_token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - branch: ${{ github.ref }} \ No newline at end of file + release_type: 'major' + github_token: ${{ secrets.OAPICF_GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/release-minor-workflow.yaml b/.github/workflows/release-minor-workflow.yaml index a7adeb3..6528217 100644 --- a/.github/workflows/release-minor-workflow.yaml +++ b/.github/workflows/release-minor-workflow.yaml @@ -3,20 +3,9 @@ name: Release Minor on: [workflow_dispatch] jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v4 + - uses: cliffano/release-action@v1.0.0 with: - token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - - uses: actions/setup-node@v4 - with: - node-version: '20' - - run: git config --global user.email "blah+pakkun@cliffano.com" - - run: git config --global user.name "pakkunbot" - - run: npm install -g rtk - - run: rtk release --release-increment-type minor - - uses: ad-m/github-push-action@master - with: - tags: true - github_token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - branch: ${{ github.ref }} \ No newline at end of file + release_type: 'minor' + github_token: ${{ secrets.OAPICF_GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/release-patch-workflow.yaml b/.github/workflows/release-patch-workflow.yaml index 043e032..ab3e154 100644 --- a/.github/workflows/release-patch-workflow.yaml +++ b/.github/workflows/release-patch-workflow.yaml @@ -3,20 +3,9 @@ name: Release Patch on: [workflow_dispatch] jobs: build: - runs-on: ubuntu-latest + runs-on: ubuntu-22.04 steps: - - uses: actions/checkout@v4 + - uses: cliffano/release-action@v1.0.0 with: - token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - - uses: actions/setup-node@v4 - with: - node-version: '20' - - run: git config --global user.email "blah+pakkun@cliffano.com" - - run: git config --global user.name "pakkunbot" - - run: npm install -g rtk - - run: rtk release --release-increment-type patch - - uses: ad-m/github-push-action@master - with: - tags: true + release_type: 'patch' github_token: ${{ secrets.OAPICF_GITHUB_TOKEN }} - branch: ${{ github.ref }} diff --git a/CHANGELOG.md b/CHANGELOG.md index 2649d25..5a9ae8f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## Unreleased +### Changed +- Update all GitHub Actions workflows to latest generator template + ## 1.1.0 - 2024-11-02 ### Changed - Upgrade Swaggy C to 4.8.0