
> ./sms-notifier sms:read /dev/ttyUSB1
INFO[2019-08-21T02:44:49+08:00] Send Bytes bytes="ATE0\r\n" length=6
INFO[2019-08-21T02:44:49+08:00] Send Bytes bytes="AT+CMEE=1\r\n" length=11
INFO[2019-08-21T02:44:49+08:00] Send Bytes bytes="AT+CMGF=0\r\n" length=11
INFO[2019-08-21T02:44:49+08:00] Listening com_port=/dev/ttyUSB1
INFO[2019-08-21T02:44:49+08:00] Incoming data data=OK
ls -l /dev/ttyUSB*> ls -l /dev/ttyUSB*
crw-rw----. 1 root dialout 188, 1 8月 21 02:47 /dev/ttyUSB0
.env.example.json -> .env.jsonpushover config in .env.jsongo run artisan.go sms:read /dev/YOUR-SERIAL, such as /dev/ttyUSB0docker run --rm -it -d \
--device=/dev/ttyUSB0 \
-e TOTOVAL_PUSHOVER_USER=YOUR_PUSHOVER_USER \
-e TOTOVAL_PUSHOVER_TOKEN=YOUR_PUSHOVER_TOKEN \
-e TOTOVAL_PUSHOVER_DEVICE="" \
toby1991/sms-forwarder:latest
/app/logics/phone/interfaces/notifier.go
package interfaces
type Notifier interface {
Notify(sender, content string) error
}
Content type
Image
Digest
Size
135.2 MB
Last updated
over 4 years ago
docker pull toby1991/sms-forwarder