-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No module named 'apt' #17
Comments
Same for me |
Finaly get this working inside docker. See my fork https://github.com/pastukhov/pkg-exporter |
|
Hi, The error is still present. Are there any updates planned to correct this error? |
How did you install it? (venv, pipx etc.) under which os? For debian 12, i added install hints to the readme. |
Thank's for the quick reply I tested on a debian 11 and installed via pip |
In general, the system apt package python3-apt needs to be installed, and the python env needs access to the system libs. Under bullseye, this worked with the system pip for me. Bookworm disabled global pip usage, i'd recommend pipx here (should also work under bullseye). Can you paste the install and the executed commands? |
To make it simpler, here is a KO dockerfile (whether with bullseye or bookworm):
I still get the error:
Whatever OS. |
I've got it working with the following dockerfile:
Not really sure yet why the inclusion of site packages is not working in your variant though. |
I have trouble installing the exporter, when I run it I get the following error:
Here are the steps I used to install the exporter on Debian:
sudp apt-get update && sudo apt-get install -y python3-apt
pip3 install git+https://github.com/margau/pkg-exporter
pkg-exporter
I confirmed this by using a fresh docker image (
python:slim-bullseye
) to run the importer inside of itThe text was updated successfully, but these errors were encountered: