Skip to content

[plugins/vsphere][feat] Move vSphere plugin to dedicated repository #541

[plugins/vsphere][feat] Move vSphere plugin to dedicated repository

[plugins/vsphere][feat] Move vSphere plugin to dedicated repository #541

name: Test and build (fixcore)
on:
push:
tags:
- "*.*.*"
branches:
- main
paths:
- 'fixcore/**'
- '.github/**'
- 'requirements-all.txt'
pull_request:
paths:
- 'fixcore/**'
- '.github/**'
- 'requirements-all.txt'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }}
cancel-in-progress: true
jobs:
fixcore-test-and-build:
name: "Test and build (fixcore)"
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./fixcore
services:
arangodb:
image: arangodb:3.8.8
env:
ARANGO_NO_AUTH: 1
ports:
- 8529:8529
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
architecture: 'x64'
- name: Setup Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Restore dependency cache
uses: actions/cache@v4
with:
# This path is specific to Ubuntu
path: ~/.cache/pip
# Look to see if there is a cache hit for the corresponding requirements file
key: ${{runner.os}}-pip-${{hashFiles('./fixcore/pyproject.toml')}}-${{hashFiles('./fixcore/requirements-all.txt')}}
restore-keys: |
${{ runner.os }}-pip-
${{ runner.os }}-
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install -r ../requirements-all.txt
pip install ../fixlib
- name: Run Tests
env:
FIXCORE_ANALYTICS_OPT_OUT: true
run: pytest
- name: Build Jupyter lite static assets
run: |
python -m pip install --upgrade pip
pip install -r requirements-jupyterlite.txt
jupyter lite build --config jupyter_lite_config.json
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
- name: Publish distribution to PyPI
if: github.ref_type == 'tag'
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_FIXINVENTORYCORE }}
packages_dir: ./fixcore/dist/