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
Credit to @feldpos for providing the original version of this file, designed for inclusion into a .bashrc etc file | |
$ ls -l /etc/pam.d/pushovernet.sh | |
-rwxr-xr-x 1 root wheel 485 Mar 22 14:48 /etc/pam.d/pushovernet.sh | |
$ cat /etc/pam.d/pushovernet.sh | |
#!/bin/sh | |
(if [ "${PAM_SM_FUNC}" == "pam_sm_open_session" ]; then | |
P_KEY="YOUR USER KEY HERE" | |
P_TOKEN="YOUR APP TOKEN HERE" | |
P_MSG="${PAM_USER} logged in to $(hostname) from ${PAM_RHOST} via ${PAM_SERVICE}" |
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
#include <PubSubClient.h> | |
#include <ESP8266WiFi.h> | |
const char* ssid = "................."; | |
const char* password = "................"; | |
char* topic = "esp8266_arduino_out"; | |
char* server = "iot.eclipse.org"; | |