mirror of
https://github.com/deuill/coreos-home-server.git
synced 2024-09-21 13:40:45 +00:00
rss2email: Use volume mounts for subscriptions
This commit updates to the latest version of RSS2Email, and uses `podman volume mount` rather than ephemeral containers for affecting changes.
This commit is contained in:
parent
219ac6f1bb
commit
bef546cb79
@ -1,5 +1,5 @@
|
||||
FROM docker.io/debian:bullseye-slim
|
||||
ARG VERSION=4a088c7efe1c76fa1ebe842adc8e2a796df8f313
|
||||
ARG VERSION=4fa34da9fbfcaa5e5496b13c4bdd17362c383568
|
||||
|
||||
RUN apt-get update -y && apt-get install -y --no-install-recommends \
|
||||
ca-certificates git gettext gosu \
|
||||
|
@ -1,20 +1,14 @@
|
||||
[Unit]
|
||||
Description=RSS Feed Subscription for %I
|
||||
Wants=container-build@rss2email.service
|
||||
After=container-build@rss2email.service
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
RemainAfterExit=true
|
||||
SyslogIdentifier=%N
|
||||
ExecStart=/bin/podman run --rm --entrypoint /bin/bash \
|
||||
--volume rss2email-feeds:/etc/rss2email/conf.d:z \
|
||||
localhost/rss2email:latest -c \
|
||||
"printf '[feed.%%s]\nurl = %I\n' $(md5sum <<< '%i' | cut -c-32) > /etc/rss2email/conf.d/%i.conf"
|
||||
ExecStop=/bin/podman run --rm --entrypoint /bin/bash \
|
||||
--volume rss2email-feeds:/etc/rss2email/conf.d:z \
|
||||
localhost/rss2email:latest -c \
|
||||
"rm -f /etc/rss2email/conf.d/%i.conf"
|
||||
ExecStart=/bin/sh -c "V=$(podman volume mount rss2email-feeds) && printf '[feed.%%s]\nurl = %I\n' $(md5sum <<< '%i' | cut -c-32) > $V/%i.conf"
|
||||
ExecStartPost=/bin/podman volume unmount rss2email-feeds
|
||||
ExecStop=/bin/sh -c "V=$(podman volume mount rss2email-feeds) && rf -f $V/%i.conf"
|
||||
ExecStopPost=/bin/podman volume unmount rss2email-feeds
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
Loading…
Reference in New Issue
Block a user