How to build and export wheel to DataBricks using GitHub actions

Viewed 53

I aim to build the wheel with GitHub actions and automatically export it to specific folder in DataBricks.

So far I have managed to build and install the wheel with:

on:
  push:
    branches:
      - main
      - master

jobs:
  build_wheel:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - name: Set up Python
        uses: actions/setup-python@v2
        with:
          python-version: 3.9
      - name: Build wheel and install
        run: |
          python -m pip install --user --upgrade build
          python -m build
          #pip install .
          find ./dist/*.whl | xargs pip install

I found a code for exporting notebooks, but not sure how it works. Maybe anyone can advice similar way of exporting wheels?

  uses: microsoft/databricks-import-notebook@v1.0.0
  with:
    databricks-host: https://adb-[Blabla].azuredatabricks.net/
    databricks-token: ${{ secrets.DATABRICKS_TOKEN }}
    local-path: ${{ github.workspace }}/notebooks
    remote-path: /from_github/${{ github.ref }}
0 Answers
Related