mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
Adding new metrics to munin.
This commit is contained in:
parent
1f04239f29
commit
5f15b12876
2 changed files with 5 additions and 1 deletions
3
fabfile.py
vendored
3
fabfile.py
vendored
|
@ -130,7 +130,8 @@ def deploy_code(copy_assets=False, full=False):
|
|||
with settings(warn_only=True):
|
||||
run('pkill -c gunicorn')
|
||||
else:
|
||||
run('kill -HUP `cat logs/gunicorn.pid`')
|
||||
run('pkill -c gunicorn')
|
||||
# run('kill -HUP `cat logs/gunicorn.pid`')
|
||||
run('curl -s http://%s > /dev/null' % env.host)
|
||||
run('curl -s http://%s/api/add_site_load_script/ABCDEF > /dev/null' % env.host)
|
||||
sudo('supervisorctl restart celery')
|
||||
|
|
|
@ -12,9 +12,12 @@ graph_config = {
|
|||
def calculate_metrics():
|
||||
from apps.rss_feeds.models import Feed
|
||||
from apps.reader.models import UserSubscription
|
||||
from apps.social.models import MSocialProfile, MSocialSubscription
|
||||
return {
|
||||
'feeds': Feed.objects.count(),
|
||||
'subscriptions': UserSubscription.objects.count(),
|
||||
'profiles': MSocialProfile.objects.count(),
|
||||
'social_subscriptions': MSocialSubscription.objects.count(),
|
||||
}
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
|
Loading…
Add table
Reference in a new issue