balena-labs-projects / balena-cam

Network Camera with Raspberry Pi and WebRTC. Tutorial:
https://balena.io/blog/build-a-raspberry-pi-based-network-camera/
MIT License
175 stars 78 forks source link
balena balenacloud camera raspberry-pi raspberry-pi-camera webrtc zerow

Live stream your balena device's camera feed.

Getting started

Running this project is as simple as deploying it to a fleet.

One-click deploy to balenaCloud:

or

Password Protect your balenaCam device

To protect your balenaCam devices using a username and a password set the following environment variables.

Key Value
username yourUserNameGoesHere
password yourPasswordGoesHere

💡 Tips: 💡

Optional Settings

TURN server configuration

If you have access to a TURN server and you want your balenaCam devices to use it. You can easily configure it using the following environment variables. When you set them all the app will use that TURN server as a fallback mechanism when a direct WebRTC connection is not possible.

Key Value
STUN_SERVER stun:stun.l.google.com:19302
TURN_SERVER turn:<yourTURNserverIP>:<yourTURNserverPORT>
TURN_USERNAME <yourTURNserverUsername>
TURN_PASSWORD yourTURNserverPassword

Additional Information

Supported Browsers

Become a balena poweruser

Want to learn more about what makes balena work? Try one of our masterclasses. Each lesson is a self-contained, deeply detailed walkthrough on core skills to be successful with your next edge project.

Check them out at our docs. Also, reach out to us on the Forums if you need help.