Add requirements.txt #1

Merged
val merged 2 commits from linnealovespie/requirements into main 2026-03-12 15:04:05 +00:00

I was trying to use the reminder plugin for maubot, only to find that the maubot image was missing some python pacakges. This PR
-adds those packages to requirements.txt,
-creates a volume to persist the package data,
-and adds a helper function to install everything in the requirements file
I could see this potentially having better ways to generalize, but this seems like a good fix for now.

I was trying to use the [reminder](https://github.com/MxMarx/reminder) plugin for maubot, only to find that the maubot image was missing some python pacakges. This PR -adds those packages to requirements.txt, -creates a volume to persist the package data, -and adds a helper function to install everything in the requirements file I could see this potentially having better ways to generalize, but this seems like a good fix for now.
linnealovespie added 1 commit 2026-02-27 06:11:17 +00:00
Owner

Ah cool you found a way to do this! Thanks.

I have no access to a computer right now, but if there is no hurry I will gladly review it in detail in like 2 weeks.

Some questions which occur directly:

  • Did you test it with a running instance, especially the replacing of an existing folder by a volume, did this work smoothly?
  • the requirements.txt, where does this come from exactly or how is it structured, would be great to indicate this in the docs
  • what do you think of putting this in a seperate, optional compose-file?
  • should we perhaps implement backup functionality first, to make sure changes won't break production?
Ah cool you found a way to do this! Thanks. I have no access to a computer right now, but if there is no hurry I will gladly review it in detail in like 2 weeks. Some questions which occur directly: - [x] Did you test it with a running instance, especially the replacing of an existing folder by a volume, did this work smoothly? - [X] the `requirements.txt`, where does this come from exactly or how is it structured, would be great to indicate this in the docs - [X] what do you think of putting this in a seperate, optional `compose`-file? - [X] should we perhaps implement backup functionality first, to make sure changes won't break production?
Author
Owner

Yay and take your time!

  1. Yes the volume for the pip install folder seems to work smoothly. We tested by mounting the volume, installing the packages, and then undeploy + redeploy. After the redeploy, the packages were still installed.
  2. I generated it by hand, but it's fairly common to have a requirements file that you feed into pip (documentation here). The requirement.txt file can also specify module versions, which might be helpful for stability.
  3. I'm not quite sure what you mean, what would be in the optional compose file?
  4. Yeah implementing backups sounds like a good idea.
Yay and take your time! 1. Yes the volume for the pip install folder seems to work smoothly. We tested by mounting the volume, installing the packages, and then undeploy + redeploy. After the redeploy, the packages were still installed. 2. I generated it by hand, but it's fairly common to have a requirements file that you feed into pip (documentation [here](https://pip.pypa.io/en/stable/reference/requirements-file-format/)). The requirement.txt file can also specify module versions, which might be helpful for stability. 3. I'm not quite sure what you mean, what would be in the optional compose file? 4. Yeah implementing backups sounds like a good idea.
val force-pushed linnealovespie/requirements from 77dc6760c1 to c1a963022d 2026-03-12 14:24:27 +00:00 Compare
Owner

Cool, I just verified for myself (and learned so) that creating a (named) volume on a exisiting folder will copy the files to the volume. So no concerns anymore :)

Will add a little doc-section and then merge it.

By a seperate compose file, I meant to add a a second compose.pip.yml or something to seperate this from default compose, so to create the volume only on installations that really need it. But let's leave it like this and seperate it when the recipe evolves and gets more complicated.

Cool, I just verified for myself (and learned so) that creating a (named) volume on a exisiting folder will copy the files to the volume. So no concerns anymore :) Will add a little doc-section and then merge it. By a seperate compose file, I meant to add a a second `compose.pip.yml` or something to seperate this from default compose, so to create the volume only on installations that really need it. But let's leave it like this and seperate it when the recipe evolves and gets more complicated.
lambdabundesverband added 1 commit 2026-03-12 15:02:53 +00:00
Owner

thanks a lot, I tried everything as well on a deployment, and can confirm it works like a charm @linnealovespie :)

thanks a lot, I tried everything as well on a deployment, and can confirm it works like a charm @linnealovespie :)
val merged commit 83c3efe4b9 into main 2026-03-12 15:04:05 +00:00
Sign in to join this conversation.
No description provided.