Skip to content

andjones132/pysqm-cdf

 
 

Repository files navigation

pysqm-cdf

Dockerfile and configuration for the PySQM software to manage a SQM-LE device.

Usage

These examples assume a CentOS 8 OS with Podman and Buildah.

Build

Build with:

buildah bud -t pysqm-img .

Run container

Assuming that the data directory is /media/pysqm, run with:

podman run --name pysqm -d -v /media/pysqm:/media/pysqm pysqm-img

Start and stop container

To run the container, it is best to generate and use a systemd unit:

podman generate systemd -n pysqm > /etc/systemd/system/pysqm.service
systemctl daemon-reload
systemctl enable pysqm.service

Upload images

Images are uploaded with the included PHP script, which can be run with

podman exec -it --user pysqm pysqm bash /home/pysqm/upload_sqm_images.sh

Periodically upload with a systemd timer

Modify upload-pysqm-images.service by inserting the correct name of the container. Once done so, install the systemd timer with:

cp upload-pysqm-images.* /etc/systemd/system
systemctl daemon-reload
systemctl --now enable upload-pysqm-images.timer

This will upload the SQM images once every 10 minutes.

About

Container Dockerfile and configuration for PySQM

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages

  • Python 71.5%
  • Dockerfile 17.7%
  • Shell 10.8%