Skip to content

Commit a3d450e

Browse files
committed
Update DEB workflow to copy .dist-info to site-packages for entry points discovery and adjust install paths accordingly
1 parent 9db65eb commit a3d450e

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

.github/workflows/publish-deb-to-release.yml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,14 @@ jobs:
4949
mkdir -p lib
5050
unzip -q dist/*.whl -d lib/
5151
52+
- name: Prepare dist-info for Salt site-packages
53+
run: |
54+
mkdir -p site-packages
55+
# Copy ONLY .dist-info to Salt's site-packages for entry_points discovery
56+
# This allows importlib.metadata to find our entry_points while keeping
57+
# the actual code isolated in /opt/saltstack/salt-bundle/lib
58+
cp -r lib/salt_bundle-*.dist-info site-packages/
59+
5260
- name: salt-bundle entrypoint (salt python)
5361
run: |
5462
mkdir -p bin
@@ -93,7 +101,8 @@ jobs:
93101
lib/=/opt/saltstack/salt-bundle/lib \
94102
bin/salt-bundle=/opt/saltstack/bin/salt-bundle \
95103
usr-bin/salt-bundle=/usr/bin/salt-bundle \
96-
pth/salt-bundle.pth=/opt/saltstack/salt/lib/python3.10/site-packages/salt-bundle.pth
104+
pth/salt-bundle.pth=/opt/saltstack/salt/lib/python3.10/site-packages/salt-bundle.pth \
105+
site-packages/=/opt/saltstack/salt/lib/python3.10/site-packages/
97106
98107
- name: Upload artifact
99108
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)