Skip to content

Commit

Permalink
new venv
Browse files Browse the repository at this point in the history
  • Loading branch information
TjerkNan committed Oct 15, 2024
1 parent 5bf7971 commit c05dac2
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions .github/workflows/build_venv.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,26 @@ jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Install required libraries
run: sudo apt install -y libsystemd-dev
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v4
- name: prep
run: sudo mkdir -p /usr/local/rdo-journalert/current/
run: sudo mkdir -p /usr/local/rdo-microsoft365-exporter/current/
- name: prep chown
run: sudo chown `id -u`:`id -g` /usr/local/rdo-journalert/current/
run: sudo chown `id -u`:`id -g` /usr/local/rdo-microsoft365-exporter/current/
- name: copy project to run location.
run: cp -r ./requirements.txt /usr/local/rdo-journalert/current/
run: cp -r ./requirements.txt /usr/local/rdo-microsoft365-exporter/current/
- name: Create env
run: python3 -m venv /usr/local/rdo-journalert/current/.venv
run: python3 -m venv /usr/local/rdo-microsoft365-exporter/current/.venv
- name: pip3 install
run: cd /usr/local/rdo-journalert/current; source .venv/bin/activate; pip install -U pip; pip install -r requirements.txt
run: cd /usr/local/rdo-microsoft365-exporter/current; source .venv/bin/activate; pip install -U pip; pip install -r requirements.txt
- name: Create archive
run: cd /usr/local/rdo-journalert/current/; tar -czf $GITHUB_WORKSPACE/rdo-journalert_venv_${{ env.RELEASE_VERSION }}.tar.gz .venv
run: cd /usr/local/rdo-microsoft365-exporter/current/; tar -czf $GITHUB_WORKSPACE/rdo-microsoft365-exporter_venv_${{ env.RELEASE_VERSION }}.tar.gz .venv
- name: Upload venv tar
uses: actions/upload-artifact@v4
with:
name: rdo-journalert_venv_${{ env.RELEASE_VERSION }}
path: rdo-journalert_venv_${{ env.RELEASE_VERSION }}.tar.gz
name: rdo-microsoft365-exporter_venv_${{ env.RELEASE_VERSION }}
path: rdo-microsoft365-exporter_venv_${{ env.RELEASE_VERSION }}.tar.gz

0 comments on commit c05dac2

Please sign in to comment.