Skip to content

fix: correct api url #29

fix: correct api url

fix: correct api url #29

Workflow file for this run

name: Deployment
on:
push:
tags: "v*"
jobs:
release:
name: Build and create release
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Get tag
run: echo ::set-output name=VERSION_TAG::${GITHUB_REF/refs\/tags\//}
id: get_tag
- name: Checkout
uses: actions/checkout@v3
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 14
- uses: pnpm/action-setup@v2
name: Install pnpm
id: pnpm-install
with:
version: 7
run_install: false
- name: Get pnpm store directory
id: pnpm-cache
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install server dependencies
run: cd server/image && pnpm install --no-frozen-lockfile
- name: Build server
run: cd server/image && pnpm build
- name: Bundle built files
run: |
mkdir -p ./temp/fivemanage_lib
cp ./fxmanifest.lua ./temp/fivemanage_lib/
cp -r ./client ./temp/fivemanage_lib/client
mkdir -p ./temp/fivemanage_lib/server
cp ./server/{main.lua,heartbeat.lua} ./temp/fivemanage_lib/server
cp -r ./server/dist ./temp/fivemanage_lib/server
cp -r ./server/logs ./temp/fivemanage_lib/server
cp -r ./shared ./temp/fivemanage_lib/shared
#cp -r ./server/dist ./temp/fivemanage_lib/server
#rm ./temp/fivemanage_lib/server/image
cd ./temp && zip -r ../fivemanage_lib ./fivemanage_lib
- name: Create Release
uses: softprops/action-gh-release@v1
with:
token: ${{ secrets.FIVEMANAGE_WORKFLOW }}
name: Fivemanage API SDK | ${{ steps.get_tag.outputs.VERSION_TAG }}
prerelease: false
files: fivemanage_lib.zip
env:
CI: false
GITHUB_TOKEN: ${{ secrets.FIVEMANAGE_WORKFLOW }}