Skip to content
This repository has been archived by the owner on Aug 26, 2021. It is now read-only.

The Docker image is hard to use on Kubernetes due to the volume #114

Open
Qonstrukt opened this issue Feb 20, 2020 · 2 comments
Open

The Docker image is hard to use on Kubernetes due to the volume #114

Qonstrukt opened this issue Feb 20, 2020 · 2 comments
Labels
enhancement New feature or request

Comments

@Qonstrukt
Copy link

Qonstrukt commented Feb 20, 2020

When running LibreSignage in Docker, one can use a named volume to retain the files in /var/www/html/data and still have a bound volume to retain those files between runs.

Kubernetes unfortunately doesn't have such functionality. Volumes mounted use the original content on the host, so the data folder becomes empty. This prevents you from logging in using the standard admin account for example.
There are ways around this using an inittcontainer and what not, but this makes the initial setup a lot harder than it has to be.

If the image could be changed so the initial files in data are created on first startup this would make the image a lot more friendly to use.

If I can find some spare time I'll try to cook something up myself and submit a PR, but I just wanted to put it out here. 🙂

@eerotal
Copy link
Owner

eerotal commented Feb 20, 2020

Ah, that's something I didn't take into account. It shouldn't be too hard to create a simple PHP script that initializes the admin account when the web interface is accessed for the first time for example.

@eerotal eerotal added the enhancement New feature or request label Feb 23, 2020
@stblassitude
Copy link

Kubernetes offers a number of drivers to have persistent data stored in the cluster. Which ones are available depends on the exact cluster configuration. See the documentation at https://kubernetes.io/docs/concepts/storage/persistent-volumes/ for Kubernetes in general, and the specific documentation for persistent volumes for your cluster. Typically, there is a default type configured, so just creating a persistent volume claim and mounting that in your pod will work.

Kubernetes would be pretty useless if it didn't provide persistent data storage facilities.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants