Skip to content

Instantly share code, notes, and snippets.

@kumekay

kumekay/snapshot.sh

Last active Jul 25, 2016
Embed
What would you like to do?
Web camera on Intel Edison with uploads to s3
photo_timestamp=$(date +%Y-%m-%d_%H%M)
fswebcam -r 1280x720 --jpeg 100 -D 3 -S 13 "${photo_timestamp}.jpg"
aws s3 cp "$photo_timestamp.jpg" "s3://$s3_bucket" && \
aws s3 cp "$photo_timestamp.jpg" "s3://$s3_bucket/latest.jpg" --acl public-read && \
rm "$photo_timestamp.jpg"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment