Improve docs how to test community containers (CC) locally? #5012
-
The documentation for adding new CCs does not cover how to develop and test containers locally before submitting a PR. I have searched the codebase, the issues and the discussions; and I am not finding documentation on this. If it exists, perhaps it should be linked more clearly? I am approaching this from the perspective of a consumer of the NextCloud AIO stack in a homelab setting, where my production server is a proxmox cluster running the stack on docker in an Ubuntu VM. My users are my family. I am primarily interested in adding new containers and modifying existing containers, but I don't have a lot of spare time--so I don't want to necessarily have to commit to going through the PR process; but if I do submit a PR, I want to be darn sure everything is as close to spotless as possible before I submit. I also don't want to have to run the codebase locally--I just want to "develop" and test CCs (assuming that is possible to isolate CCs from the rest of the stack for the purpose of development and testing). I imagine that there are more than a few AIO users who share this perspective (homelab or small org admins who run AIO in production and want to extend their instance with new functionality). I do not have a staging environment. I make all of my changes on production. Since everything is running inside a VM, I can snapshot and rollback anytime I want to test/revert changes. I'm comfortable with short periods of downtime that I control. From this perspective: off the top, there are a few possible use cases that could be documented a little more clearly:
Once it's clear how to inject new AIO containers from local code, it might be possible to extrapolate how one might support a 3rd party repository of containers (or any arbitrary collection of containers that are not centrally defined in the AIO repo), which would be exceptionally useful for users who are primarily interested in running the NextCloud AIO stack and extending its functionality via CCs. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
Hi, thanks a lot for bringing this up! I agree we need more documentation on the topic. Help on this is very appreciated :)
We don't have plans to document this case for now as you can very easily create additional docker containers without using AIOs CC feature for that. But it shouldn't be much different compared to how to test container candidate locally before submitting PR. See below
In general, see #4822 (comment)
Mostly the following workflows need to pass: https://github.com/nextcloud/all-in-one/blob/main/.github/workflows/json-validator.yml and https://github.com/nextcloud/all-in-one/blob/main/.github/workflows/community-containers.yml
In general, the jsons are validated against this json schema: https://github.com/nextcloud/all-in-one/blob/main/php/containers-schema.json. There indirectly all possible values are documented. A very much complete example can be found here: https://github.com/nextcloud/all-in-one/blob/main/php/containers.json Regarding the community container caddy, new containers that are covered can be easily added by submitting a PR to this repo: https://github.com/szaimen/aio-caddy. See e.g. szaimen/aio-caddy#40 |
Beta Was this translation helpful? Give feedback.
-
I've added this to the list in #5251 now |
Beta Was this translation helpful? Give feedback.
I've added this to the list in #5251 now