summaryrefslogtreecommitdiffstats
path: root/roles/prerec/templates/process-prerec.sh
diff options
context:
space:
mode:
authorSacha Chua <sacha@sachachua.com>2024-10-01 19:59:03 -0400
committerSacha Chua <sacha@sachachua.com>2024-10-01 19:59:03 -0400
commit2be81b299be9cad0b03495f2ea038a01969c6cb2 (patch)
tree6f798cdf8233d0c1079eaff3a52fd3bdabf8bdf7 /roles/prerec/templates/process-prerec.sh
parenta50799ae2d27ea57f9f470a9ecfb06dd77499c34 (diff)
downloademacsconf-ansible-2be81b299be9cad0b03495f2ea038a01969c6cb2.tar.xz
emacsconf-ansible-2be81b299be9cad0b03495f2ea038a01969c6cb2.zip
Update for new ansible version
Diffstat (limited to '')
-rwxr-xr-xroles/prerec/templates/process-prerec.sh11
1 files changed, 3 insertions, 8 deletions
diff --git a/roles/prerec/templates/process-prerec.sh b/roles/prerec/templates/process-prerec.sh
index 795753d..d98337f 100755
--- a/roles/prerec/templates/process-prerec.sh
+++ b/roles/prerec/templates/process-prerec.sh
@@ -5,14 +5,9 @@ ORIGINAL=$1
REENCODED=$(echo "$ORIGINAL" | perl -pe 's/^(emacsconf-[0-9]*-.*?--.*?--.*?--).*/$1reencoded.webm/')
SLUG=$(echo "$ORIGINAL" | perl -ne '/^emacsconf-[0-9]*-(.*?)--/ && print $1')
MAIN=$(echo "$ORIGINAL" | perl -pe 's/^(emacsconf-[0-9]*-.*?--.*?--.*?--).*/$1main.webm/')
-SCREEN=reencode-$SLUG
-if ! ( screen -ls | grep -q $SLUG ); then
- screen -dmS $SCREEN
-fi
# ( cd /data/emacsconf/cache; ./update-cache )
-# /data/emacsconf/{{ emacsconf_year }}/scripts/talk $SLUG "WAITING_FOR_PREREC" "PROCESSING"
+# /data/emacsconf/admin/{{ emacsconf_year }}/scripts/talk $SLUG "WAITING_FOR_PREREC" "PROCESSING"
if [[ ! -f "$REENCODED" ]]; then
- screen -S $SCREEN -X screen -t reencode-$SLUG /bin/bash -c "/data/emacsconf/{{ emacsconf_year }}/scripts/reencode.sh \"$ORIGINAL\" \"$REENCODED\" && /data/emacsconf/{{ emacsconf_year }}/scripts/upload.sh $REENCODED $MAIN && /data/emacsconf/{{ emacsconf_year }}/scripts/thumbnail.sh \"$MAIN\" && /data/emacsconf/{{ emacsconf_year }}/scripts/upload.sh $(echo "$MAIN" | sed s/webm$/png/) exec /bin/bash" &
+ screen -dmS reencode-$SLUG /bin/bash -c "reencode.sh \"$ORIGINAL\" \"$REENCODED\" && upload.sh $REENCODED $MAIN && thumbnail.sh \"$MAIN\" && upload.sh $(echo "$MAIN" | sed s/webm$/png/); echo $(date -Iminutes) $SLUG reencoded >> ~/emacsconf.log && exec /bin/bash" &
fi
-screen -S $SCREEN -X screen -t captions-$SLUG /bin/bash -c "/data/emacsconf/{{ emacsconf_year }}/scripts/process-captions.py $(dirname $ORIGINAL); exec /bin/bash"
-screen -x $SCREEN
+screen -dmS captions-$SLUG /bin/bash -c "/data/emacsconf/admin/{{ emacsconf_year }}/scripts/process-captions.py $(dirname $ORIGINAL); echo $(date -Iminutes) $SLUG captioned >> ~/emacsconf.log; exec /bin/bash"