Last active
April 24, 2024 06:38
-
-
Save TopperBG/4f9e0074ccdfb0dc84c2d1af6711a7f6 to your computer and use it in GitHub Desktop.
Run PMM detached removable container when Tautulli detect movie/series import in Plex
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/etc/docker/daemon.json <- where to save a file, remove that line after that | |
{ | |
"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/etc/systemd/system/docker.service.d/override.conf <- where to save a file, remove that line after that | |
[Service] | |
ExecStart= | |
ExecStart=/usr/bin/dockerd --config-file /etc/docker/daemon.json --containerd=/run/containerd/containerd.sock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Place sciprt in /config folder, mapped in Tatulli container. Change 192.168.1.110 according your setup. | |
curl -X DELETE "http://192.168.1.110:2375/containers/pmm-temp" | |
curl -X POST -H "Content-Type: application/json" "http://192.168.1.110:2375/containers/create?name=pmm-temp" -d '{ | |
"Image": "kometateam/imagemaid", | |
"Cmd": ["--overlays", "--run", "-ig", "--ignore-schedules", "--no-missing"], | |
"HostConfig": { | |
"Binds": ["/root/docker/etc/plexmetamanager:/config"], | |
"AutoRemove": true | |
} | |
}' | |
curl -X POST -H "Content-Type: application/json" "http://192.168.1.110:2375/containers/pmm-temp/start" | |
TIMESTAMP=`date "+%Y-%m-%d %H:%M:%S"` | |
echo "PMM run at $TIMESTAMP" >> /config/pmm-temp.log | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment