lxdock
lxdock copied to clipboard
Document container naming mechanism
When using the sample lxdock.yml, I get containers whose names are <project name>-<container name>-<some digits>
.
+--------------------------+---------+---------------------+------+------------+-----------+
| myproject-test01-5902851 | RUNNING | | | PERSISTENT | 0 |
+--------------------------+---------+---------------------+------+------------+-----------+
| myproject-test02-5902851 | RUNNING | | | PERSISTENT | 0 |
+--------------------------+---------+---------------------+------+------------+-----------+
I couldn't see any documentation about how containers are named, and it's not easy to find in the code either. I did eventually find it - it seems the suffix is project_id
and comes from the inode number of the containing folder.
Worth adding a note to the documentation?
Maybe worth adding something short about this. As far as I know the reason for this is that some people may want to clone the same project in two locations, do a lxdock up, and end up with two differently named containers.
This issue should be about being able to customize this. I don't like having this. In my scripting I have to parse lxd outputs to do anything with the container.