Skip to content

Instantly share code, notes, and snippets.

@morenopc
Created July 23, 2013 14:58
Show Gist options
  • Select an option

  • Save morenopc/6063003 to your computer and use it in GitHub Desktop.

Select an option

Save morenopc/6063003 to your computer and use it in GitHub Desktop.
Twitneraio: Shell script send tweets
Tue Jul 23 14:30:08 UTC 2013
/var/lib/openshift/51ede3a585194317da000107/python-2.7/virtenv/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory
Tue Jul 23 14:45:08 UTC 2013
/var/lib/openshift/51ede3a585194317da000107/python-2.7/virtenv/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory
#!/bin/sh
if [ $(($(date +%M) % 15)) -eq 0 ]; then
LOGS_DIR="$OPENSHIFT_HOMEDIR"python-2.7/logs
PROJECT_ROOT="$OPENSHIFT_HOMEDIR"python-2.7/repo/wsgi/openshift
mkdir -p $LOGS_DIR/cron-logs
date >> $LOGS_DIR/cron-logs/cron_send_tweet.log 2>&1
"$OPENSHIFT_HOMEDIR"python-2.7/virtenv/bin/python $PROJECT_ROOT/manage.py cron send_tweets >> $LOGS_DIR/cron-logs/cron_send_tweet.log 2>&1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment