feat: upgrade CI Node.js version to 20 #28
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: 1.19 | |
- name: Set up Docker | |
uses: docker-practice/actions-setup-docker@master | |
- name: Set up Server | |
run: | | |
set -x | |
docker version | |
docker run -id -p 50051:50051 \ | |
-e CONNECTION_CONFIG_PATH=/config/connection_config.json \ | |
-v $GITHUB_WORKSPACE/config:/config \ | |
-v $GITHUB_WORKSPACE/examples:/data/examples \ | |
--name my-casbin-server-config \ | |
-d casbin/casbin-server | |
- name: Go Test | |
run: go test ./... | |
semantic-release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 20 | |
- name: Run semantic-release | |
if: github.repository == 'casbin/casbin-go-client' && github.event_name == 'push' | |
run: | | |
export PATH="$(yarn global bin):$PATH" | |
yarn global add semantic-release | |
semantic-release | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |