Yes, several FOSS options exist. But make sure that the data can be locked and accessible in the event that you're in a crash and unable to retrieve the data yourself.
I ride with a dashcam, always. But I am considering a rear camera because more and more asshats dangerously come up from behind.