Add generic Luigi install logic
at least try to do what we can to reduce boilerplate
This commit is contained in:
parent
ca59000287
commit
6bf697da1d
9 changed files with 302 additions and 0 deletions
28
rattail_fabric2/deploy/luigi/overnight.sh.mako
Executable file
28
rattail_fabric2/deploy/luigi/overnight.sh.mako
Executable file
|
@ -0,0 +1,28 @@
|
|||
#!/bin/bash
|
||||
<%text>############################################################</%text>
|
||||
#
|
||||
# overnight automation for '${automation}'
|
||||
#
|
||||
<%text>############################################################</%text>
|
||||
|
||||
set -e
|
||||
|
||||
DATE=$1
|
||||
|
||||
if [ "$1" = "--verbose" ]; then
|
||||
DATE=$2
|
||||
VERBOSE='--verbose'
|
||||
else
|
||||
VERBOSE=
|
||||
fi
|
||||
|
||||
if [ "$DATE" = "" ]; then
|
||||
DATE=`date --date='yesterday' +%Y-%m-%d`
|
||||
fi
|
||||
|
||||
LUIGI='${envroot}/bin/luigi --logging-conf-file logging.conf'
|
||||
export PYTHONPATH=${appdir}
|
||||
|
||||
cd ${appdir}/luigi
|
||||
|
||||
$LUIGI --module luigitasks.overnight_${automation.lower()} Overnight${automation} --date $DATE
|
Loading…
Add table
Add a link
Reference in a new issue