pushover-log-route Send logs to your mobile device by http://pushover.net/

Yii PushoverLogRoute extension

  1. Requirements
  2. Installation
  3. Additional config params
  4. Resources

Send logs to your mobile device by Pushover.net. Recommended for alarm reports or non-frequent messages.

  • Immediate log dilevery
  • Customized notification diliverying (silent hours, level, sounds) via pushover service API.

Requirements

  • Yii Framework 1.1.x (tested on 1.1.14)
  • php.ini directive allow_url_fopen enabled

Installation

  • Step 1: Put directory PushoverLogRoute (or only PushoverLogRoute.php) into your framework extensions directory.
  • Step 2: Create account on http://pushover.net/ and register your application (yii-logo.png for application icon included).
  • Step 3: Add PushoverLogRoute as new log route on framework config:
'components' => array(
    'log' => array(
        'class' => 'CLogRouter',
        'routes' => array(
            array(
                'class'   => 'ext.PushoverLogRoute.PushoverLogRoute',
                'token'   => '*your-token-on-pushover*',
                'userKey' => '*your-user-key-on-pushover*',
            ),
        ),
    ),
),

Additional config params

array(
    'class'   => 'ext.PushoverLogRoute.PushoverLogRoute',
    'token'   => '*your-token-on-pushover*',
    'userKey' => '*your-user-key-on-pushover*',

    //Customize logging levels
    'levels' => 'warning, error', //Important: by default level set to 'error' only

    //Customize API params for all notify
    'options' => array(
        'url' => 'http://example.com/',
        'url_title' => 'Go to app',
    ),

    //Cutomize API params by level
    'levelOptions' => array(
        //Set normal priority and silent notify for error level
        'error' => array(
            'priority' => 0,
            'sound' => 'none',
        ),
        //Set sound for info level
        'info' => array(
            'sound' => 'bike',
        ),
    ),
)

Resources

1 0
3 followers
254 downloads
Yii Version: Unknown
License: BSD-2-Clause
Category: Logging
Developed by: Yiivgeny
Created on: Sep 11, 2013
Last updated: 10 years ago

Downloads

show all

Related Extensions