~fancycade/erlpic

Erlang + OpenCV for periodic pictures
Set interval to 5 minutes
Fix erlpic.service file
Update timeout and sync interval

refs

main
browse  log 

clone

read-only
https://git.sr.ht/~fancycade/erlpic
read/write
git@git.sr.ht:~fancycade/erlpic

You can also use your local clone with git send-email.

#erlpic

Take a picture and upload it to s3 with Erlang.

#Install

apt install erlang rebar3 make g++ libopencv-dev

#Build

rebar3 compile

#Usage

rebar3 shell

#Config

config/sys.config.src

Set device to device number (default 0). Set resolution to {0, 0} to use defaults (default 1920 x 1080).

Set AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY in .profile of the user.

#Systemd

Edit and copy erlpic.service to /etc/systemd/system/

As root user run these commands:

systemctl enable erlpic.service
systemctl start erlpic.service
systemctl status erlpic.service

To view running logs:

journalctl -u erlpic.service -f