Anytime my server restarts, I have to re-run a script to completely re-create the server. Which is another ongoing issue that I can’t seem to get a straight answer to.
That script follows:
#
# Update docker and (re)create container
#
# Update image first
Image="$(sudo docker images | grep plex | awk '{print $3}')"
if [ "$Image" != "" ]; then
sudo docker stop plex
sudo docker stop plex
sudo docker rm plex
sudo docker rmi -f $Image
fi
sudo docker run \
-d \
--name plex \
--network=host \
-e PLEX_CLAIM="claim-qPpfokcN_RhDdhe7uTrk" \
-e TZ="EST" \
-e LANG="en_US.UTF-8" \
-e PLEX_UID=1000 \
-e PLEX_GID=1000 \
-e PUID=1000 \
-e PGID=1000 \
-h plex-omv \
-v /Storage/Plex-OMV:/config \
-v /Storage/Video/Movies:/movies \
-v /Storage/Video/TV:/tv \
-v /vie:/data \
--device=/dev/dri:/dev/dri \
plexinc/pms-docker:plexpass
docker start plex
docker update --restart=unless-stopped plex
From reviewing this script, it seems the following lines
-v /Storage/Video/Movies:/movies
-v /Storage/Video/TV:/tv \
are the piece of syntax that specify the folders that contain movies and tv shows.
From a linux prompt, if I browse to the /Storage/Video/TV path, sure enough, that is where my TV shows are.
However, what doesn’t make sense to me is that the movie path is incomplete - that’s a parent folder that contains more than just movie rips for plex.
When I go into app.plex.tv, and go into settings, and go into manage - libraries, and hover over movies, and select the option to edit it, it shows this:
I don’t understand how my script I have to run everytime I restart to get my server back specifies the parent folder, yet the library itself is pointing to a folder within that folder.
I don’t know how any of this got set like this in the first place.
So, meanwhile, I have several folders contained in a path of /Storage/Media
Some of these folders I’d like to add as music libraries, but I want them to show up separately somehow, since there may be duplicates of albums which will confuse things and make things a navigation nightmare (having the same album on a CD, vs DVD, vs DVD-A, vs SACD, vs blu-ray)
So I guess a list of questions I have at this point is:
would the syntax of -v /Storage/Media:/music \ be involved in adding this folder to show up when adding a library?
If so, how do I run that, as that is part of a fuller syntax, and re-running the whole script every time is probably not correct?
Also - what do I need to do to not have to run this full script every time my server needs a restart?
MODERATOR EDIT: Code legibility