forked from stringer-rss/stringer
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request stringer-rss#459 from pascalw/feature/update-docke…
…r-docs Update Docker docs to use image on Docker Hub
- Loading branch information
Showing
2 changed files
with
31 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,21 @@ | ||
#!/usr/bin/env sh | ||
if [ -z "$DATABASE_URL" ]; then | ||
cat <<-EOF | ||
$(tput setaf 1)Error: no DATABASE_URL was specified. | ||
For a quick start use DATABASE_URL="sqlite3:':memory:'" | ||
(not recommended for production). | ||
EOF | ||
|
||
exit 1 | ||
fi | ||
|
||
: ${FETCH_FEEDS_CRON:='*/5 * * * *'} | ||
: ${CLEANUP_CRON:='0 0 * * *'} | ||
|
||
cat <<EOF > /app/crontab | ||
$FETCH_FEEDS_CRON cd /app && bundle exec rake fetch_feeds | ||
$CLEANUP_CRON cd /app && bundle exec rake cleanup_old_stories | ||
cat <<-EOF > /app/crontab | ||
$FETCH_FEEDS_CRON cd /app && bundle exec rake fetch_feeds | ||
$CLEANUP_CRON cd /app && bundle exec rake cleanup_old_stories | ||
EOF | ||
|
||
exec /usr/bin/supervisord -c /etc/supervisord.conf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters