Skip to content

Instantly share code, notes, and snippets.

View anthonyeden's full-sized avatar
💭
Working on changing the world.

Anthony Eden anthonyeden

💭
Working on changing the world.
View GitHub Profile
@anthonyeden
anthonyeden / config.md
Created March 31, 2018 06:31
Wordpress Caching with Nginx FastCGI

These instructions allow you to setup basic Nginx FastCGI caching for Wordpress. It ensures all admin users, and non-GET requests, bypass the cache.

Create directories with the following commands:

mkdir -p /var/cache/nginxfastcgi
chown www-data: /var/cache/nginxfastcgi

Add the following to the main server blockin your site's .conf file:

fastcgi_cache_key $scheme$request_method$host$request_uri;

@anthonyeden
anthonyeden / ZettaBackgroundRecorderTimestamper.py
Created March 31, 2018 06:26
RCS Zetta: Background Recorder Timestamper
"""
Zetta Background Recorder Timestamper
This script appends the last-modified timestamp string to assets that are updated by the background recorder.
Written by Anthony Eden (https://mediarealm.com.au)
"""
import pypyodbc
import time
import datetime
@anthonyeden
anthonyeden / ZettaRemoveDeletionDates.py
Created March 31, 2018 06:20
RCS Zetta: Deletion Date Remover
"""
Zetta Deletion Date Remover
This script will remove all deletion dates from assets in the Zetta DB, except Voice Tracks and Quick Records.
Written by Anthony Eden (https://mediarealm.com.au/)
"""
import os
import sys
import json
@anthonyeden
anthonyeden / ZettaBatchExport.py
Last active March 31, 2018 06:20
RCS Zetta: Batch Export Audio Files
"""
Zetta Batch Audio Exporter
Given a list of External IDs, find each asset's file in the Zetta Content Store, and copy it to a separate folder.
Written by Anthony Eden (https://mediarealm.com.au)
"""
from shutil import copyfile
import os
import pypyodbc
@anthonyeden
anthonyeden / ZettaExternalIDs.py
Last active March 31, 2018 06:20
RCS Zetta External ID Finder
"""
Zetta External ID Finder
This script is designed to find a selection of usable numeric External IDs in Zetta.
It only looks for five-digit codes. It will output these to a file.
Written by Anthony Eden (https://mediarealm.com.au)
"""
import os
@anthonyeden
anthonyeden / MetaRadioStationPlaylist.xml
Last active May 19, 2023 06:51
MetaRadio: StationPlaylist Studio XML Template
<StationPlaylist><artist><![CDATA[%a]]></artist><title><![CDATA[%t]]></title><album><![CDATA[%T]]></album><duration>%S</duration><starttime>%d %h</starttime><filename><![CDATA[%f]]></filename><comment><![CDATA[%C]]></comment></StationPlaylist>
@anthonyeden
anthonyeden / MetaRadioSAMBroadcaster.xml
Created March 25, 2018 08:15
MetaRadio: SAM Broadcaster XML Template
<SAMBroadcaster>
<title><![CDATA[$song.title$]]></title>
<artist><![CDATA[$song.artist$]]></artist>
<duration>$song.SS$</duration>
<startTime>$NOW$</startTime>
<assetType>$song.songtype$</assetType>
<playoutId><![CDATA[$song.FILEFULL$]]></playoutId>
</SAMBroadcaster>
@anthonyeden
anthonyeden / MetaRadioProppFrexx.xml
Created March 25, 2018 07:51
MetaRadio: ProppFrexx XML Command Template
127.0.0.1:8016|<ProppFrexx><event><![CDATA[${event}]]></event><artist><![CDATA[${plstrackartistcurrent}]]></artist><title><![CDATA[${plstracktitlecurrent}]]></title><duration>${effectivesec}</duration><starttime>${effectivestart}</starttime><filename><![CDATA[${filename}]]></filename></ProppFrexx>
@anthonyeden
anthonyeden / MetaRadioMAirList.xml
Last active November 11, 2018 05:25
MetaRadio: mAirList XML Template
<mAirList>
<title>%b</title>
<artist>%a</artist>
<duration>%l</duration>
<startTime>%S{dd/mm/yyyy hh:nn:ss am/pm}</startTime>
<endTime>%F{dd/mm/yyyy hh:nn:ss am/pm}</endTime>
<assetType>%J</assetType>
<playoutId>%1</playoutId>
<externalId>%V</externalId>
</mAirList>
@anthonyeden
anthonyeden / MetaRadioSimian.xml
Created March 25, 2018 07:41
MetaRadio Simian Pro XML Template
<?xml version="1.0"?>
<MetaNow>
<Type><![CDATA[%CATEGORY%]]></Type>
<StartTimestamp><![CDATA[%CURDATE% %CURTIME%]]></StartTimestamp>
<Duration>%LENGTHSECONDS%</Duration>
<Title><![CDATA[%TITLE%]]></Title>
<Artist><![CDATA[%ARTIST%]]></Artist>
<Album><![CDATA[%ALBUM%]]></Album>
<Filename><![CDATA[%FILENAME%]]></Filename>
</MetaNow>