This document aims to get you get up and running for Owncast development. If you’d like further details in contributing to the Owncast project, including opportunities to contribute in non-technical ways, read the Contributor Guide .
Owncast is a straightforward web application and compared to many projects is very easy to get running locally and contributing to.
The frontend consists of the interface you use when you interact with Owncast, such as the player, chat and all of the components on the page. It also includes the Owncast admin where Owncast is configured.
It is written in JavaScript, and uses React. See below on how to setup your development environment. There are details in how we build frontend React components here: How we develop frontend components
The Owncast backend is the service that powers all the features and functionality of the service. This includes the video pipeline, web server, chat service, inbound RTMP server, ActivityPub/Fediverse integration, and more. You may be interested in reading about how our APIs are built.
If you’re looking to take part in writing Owncast code, you’ll need to set up your development environment. It is a straightforward web application and compared to many projects is quite easy to get running locally and contributing to.
git clone <https://github.com/yourusername/owncast
>In order to work on Owncast you’ll need an instance of Owncast running in your development environment.
ffmpeg
installed on your machine that is available either globally, or in the same directory as the Owncast code you cloned is required.gcc
and its development libraries.go run main.go
from the root of the repository.Go Linting + Code formatting
We use golangci-lint to lint our Go code. While optional, it is a useful tool to assist you in writing better Go code. You can install it from the golangci-lint website.
If you’re looking to work on the web frontend, once you have the code downloaded, and Owncast running in you development environment, you can start the frontend.
web
directory and install dependencies with npm install
.npm run dev
.http://localhost:3000
in your browser.Storybook is a tool that allows you to create and test components in isolation. It's a great way to develop new frontend components and test them out without running a copy of the Owncast server. You can see a hosted example of it running to browse existing components at:
https://owncast.online/components
npm run storybook
to start the Storybook server.http://localhost:6006
in your browser.Frontend linting + Code formatting
We use Prettier and eslint to format and lint our Javascript + Typescript code. While optional, they are useful tools to assist you in writing frontend code. It is recommended to set up these tools to run in your code editor, but you can also run them manually, or not at all. However, if you have linting or incorrect formatting, you will receive errors in any PRs, and they will need to be fixed before they can be merged in.