added p16 branch #44
This file contains hidden or 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: Run Workflow and Deploy to GitHub Pages | |
| permissions: | |
| contents: write | |
| on: | |
| push: | |
| branches: | |
| - main # Run the workflow on pushes to the main branch | |
| - p16-benchmark # Run the workflow on pushes to the p16-benchmark branch | |
| pull_request: | |
| branches: | |
| - main # Optionally run on pull requests to the main branch | |
| - p16-benchmark # Optionally run on pull requests to the p16-benchmark branch | |
| jobs: | |
| ##################################### | |
| # using Github public runner | |
| ##################################### | |
| public-build: | |
| if: github.ref != 'refs/heads/p16-benchmark' | |
| #runs-on: p16-benchmark-corese | |
| runs-on: ubuntu-latest # Use the latest Ubuntu runner | |
| steps: | |
| # Step 1: Checkout the repository | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| # Step 2.1: Create and activate conda environment, install dependencies | |
| - name: Set up conda environment | |
| uses: conda-incubator/setup-miniconda@v3 | |
| with: | |
| environment-file: python-utils/environment.yml | |
| activate-environment: benchmarkenv | |
| auto-activate-base: false | |
| # Step 2.2: Create and activate conda environment, install dependencies | |
| - name: Run workflow | |
| shell: bash -l {0} | |
| env: | |
| RUNNER_ENV: github-public | |
| run: | | |
| conda info --envs | |
| cd python-utils | |
| python workflow.py --triplestoreNames="rdf4j.5.1.2,jena.5.4.0,corese.4.6.3" | |
| # Step 3 : Debugging step: Check if the public directory exists | |
| - name: Check public directory is here and contains required files | |
| run: ls -la ./public | |
| # Step 4: Deploy the dashboard folder to GitHub Pages | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./public # Path to the folder containing the HTML files | |
| force_orphan: true # Overwrite the gh-pages branch | |
| ##################################### | |
| # using P16 private runner | |
| ##################################### | |
| private-build: | |
| if: github.ref == 'refs/heads/p16-benchmark' | |
| runs-on: p16-benchmark-corese | |
| steps: | |
| # Step 1: Checkout the repository | |
| - name: Checkout repository | |
| uses: actions/checkout@v3 | |
| # Step 2: Create and activate conda environment, install dependencies | |
| - name: Create and activate conda environment | |
| env: | |
| RUNNER_ENV: P16-benchmark | |
| run: | | |
| source ~/miniconda3/bin/activate | |
| conda env update -f python-utils/environment.yml | |
| source $HOME/miniconda3/etc/profile.d/conda.sh | |
| conda activate benchmark_env | |
| conda info --envs | |
| cd python-utils | |
| python workflow.py | |
| # Debugging step: Check if the public directory exists | |
| - name: Check public directory is here and contains required files | |
| run: ls -la ./public | |
| # Step 3: Deploy the dashboard folder to GitHub Pages | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v3 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| publish_dir: ./public # Path to the folder containing the HTML files | |
| force_orphan: true # Overwrite the gh-pages branch |