@@ -51,33 +51,31 @@ jobs:
5151 github_token : ${{ github.token }}
5252 workflow : " .github/workflows/import_packages.yml"
5353 workflow_conclusion : success
54- name : backup_weaviate
54+ name : sqlite_vectordb_file
5555 path : /tmp/
5656 name_is_regexp : true
5757 skip_unpack : false
58- if_no_artifact_found : ignore
58+ if_no_artifact_found : ignore
5959
60- - name : Create folder if artifact download is not enabled
61- if : ${{ github.event.inputs.enable_artifact_download == 'false' }}
60+ - name : Install Poetry
6261 run : |
63- mkdir -p /tmp/backup_weaviate
64- echo "Folder ./backup_weaviate created because artifact download is disabled."
62+ curl -sSL https://install.python-poetry.org | python3 -
6563
66- - name : Run sync
64+ - name : Add Poetry to PATH
6765 run : |
68- export PYTHONPATH=$PYTHONPATH:./
69- export BACKUP_FILESYSTEM_PATH=/tmp/backup_weaviate/
70- export BACKUP_FOLDER=backup
71- # Conditionally export the variables only if artifact download is enabled
72- if [ "${{ github.event.inputs.enable_artifact_download }}" == "true" ]; then
73- python scripts/import_packages.py --jsonl-dir /tmp/jsonl-files/
74- else
75- python scripts/import_packages.py --restore-backup False --jsonl-dir /tmp/jsonl-files/
76- fi
66+ echo "source $HOME/.poetry/env" >> $GITHUB_ENV
7767
78- - name : ' Upload Backup Files'
68+ - name : Install dependencies with Poetry
69+ run : |
70+ poetry install
71+
72+ - name : ' Run import_packages.py with poetry'
73+ run : |
74+ poetry run python scripts/import_packages.py --jsonl-dir /tmp --vec-db-path /tmp/sqlite_data/vectordb.db
75+
76+ - name : ' Upload SQLite Vector DB File'
7977 uses : actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b # v4
8078 with :
81- name : backup_weaviate
82- path : /tmp/backup_weaviate/backup*
79+ name : sqlite_vectordb_file
80+ path : /tmp/sqlite_data/vectordb.db
8381 retention-days : 90
0 commit comments