使用者工具

網站工具


linux:monitor:zabbix_alert

差異處

這裏顯示兩個版本的差異處。

連向這個比對檢視

Both sides previous revision 前次修改
下次修改
前次修改
linux:monitor:zabbix_alert [2014/03/23 14:20]
ali88 [申請使用Google API金鑰]
linux:monitor:zabbix_alert [2014/03/23 18:00] (目前版本)
ali88
行 8: 行 8:
 #​easy_install rfc3339 #​easy_install rfc3339
 #​easy_install google-api-python-client</​code>​ #​easy_install google-api-python-client</​code>​
 +{{:​linux:​monitor:​google_calendar.png?​300|}}
 =====申請使用Google API金鑰===== =====申請使用Google API金鑰=====
 因為是使用Google API,​需要到 https://​code.google.com/​apis/​console/​ (使用google帳號登入)申請API金鑰。 因為是使用Google API,​需要到 https://​code.google.com/​apis/​console/​ (使用google帳號登入)申請API金鑰。
行 94: 行 95:
 print created_event['​id'​] print created_event['​id'​]
 </​code>​ </​code>​
 +  - 執行此程式 ​ 參數1:​日曆ID(google mail ) 2.標題 3.說明)<​code>#​python gapi_calendar.py [email protected] TilteTest88 contextTest88</​code>​
 +      * 使用此程式產生的**網址進行授權** 要求是否允許 使用google API 發送訊息到日曆ID{{:​linux:​monitor:​api_cmd.png?​700|}}{{:​linux:​monitor:​api_htmlauth.png?​600|}}{{:​linux:​monitor:​api_htmlauthcode.png?​300|}}
 +      * 貼上授權碼後完成授權 , 會在目錄下產 calendar.dat{{:​linux:​monitor:​api_cmd2.png?​700|}}
 +      * 送出events 後會print event id ,​就完成了。{{:​linux:​monitor:​api_cmd3.png?​700|}}{{:​linux:​monitor:​google_calendar.png?​700|}}
  
 +======參考資料======
 +  * [[http://​jerry2yang.wordpress.com/​2012/​02/​06/​ubuntu-install-google-calendar-api-with-python/​|Ubuntu install google calendar api with python]]
 +  * [[https://​www.evernote.com/​shard/​s112/​sh/​0db8e94a-8c19-4272-b1b8-392c4a623bb6/​063809b3590dd7ea095cc0fd87a95a27?​noteKey=063809b3590dd7ea095cc0fd87a95a27&​noteGuid=0db8e94a-8c19-4272-b1b8-392c4a623bb6|JasonW同事-使用GOOGLE 日曆功能 發送SMS]]
 +  * [[http://​www.openfoundry.org/​tw/​tech-column/​8536-introduction-of-python-extension-management-tools|Python 套件管理程式簡介]]
linux/monitor/zabbix_alert.1395584403.txt.gz · 上一次變更: 2014/03/23 14:20 由 ali88