GitFOSS
efb87ba (parent 7b50ebe)6/10/2026, 1:34:35 PM

Read Me

❇️ GitFOSS

GitFOSS is a small and simple, free and open-source Git Forge built w/ Node.JS, Fastify, Prisma and React!

Run it

In order to run your own instance of GitFOSS, the first step is to clone this git repository and cd into it:

$ git clone https://gitfoss.io/ethicdevs/gitfoss.git
$ cd gitfoss/

Locally via Node/Yarn

Development mode

Make sure your .env.local file is correctly setup and includes all the environment variables present in the example .env file. Make sure no value is set to fake.

$ yarn dev # Run dev 'server'
$ yarn typecheck # Check TypeScript types validity
$ yarn test # Run app tests

Also when performing changes to the Prisma schema, don't forget to make a new migration files using the following command:

$ yarn migrate:dev # Create a new migration file interactively

Production-like mode

Make sure your .env.production file is correctly setup and includes all the environment variables present in the example .env file. Make sure no value is set to fake.

$ yarn build
$ cp .env.production dist/.env.production
$ DATABASE_URL='postgresql://...from.env.production...' yarn migrate:deploy
$ yarn start

Using Docker

$ docker run -p 1337:1337 \
  -e COOKIE_NAME='gitfoss_ssid' \
  -e COOKIE_SECRET='change_me_cookie_secret' \
  -e DATABASE_URL='postgresql://...from.env.production...' \
  -e DEPLOYMENT_DOMAIN='local-app.localhost' \
  -e DEPLOYMENT_SCHEME='http' \
  -e GIT_REPOSITORIES_ROOT='/var/lib/gitfoss/repos' \
  docker.io/library/gitfoss_web:latest

# Get the container id then run migrations
$ docker exec -it <container_id_here> yarn migrate:deploy

Using docker-compose

$ docker-compose up -d
$ docker-compose exec web yarn migrate:deploy

We also have a docker-compose.caddy.yml and docker-compose.traefik.yml for running GitFOSS using Caddy and Traefik reverse-proxies respectively.

Logs

  • /var/log/gitfoss/git_ssh.log: Whatever happens on git over ssh
  • /var/log/gitfoss/git_http.log: Whatever happens on git over http(s)
  • /var/log/gitfoss/web.log: Whatever happens over web ui
  • /var/log/gitfoss/ci.log: Whatever happens over CI
  • /var/log/gitfoss/ci-runner-$n.log: Whatever happens over CI runner $n

License

This project is licensed under the MIT license.

GitFOSS hosted on GitFOSS! :)

https://gitfoss.dev

gitfoss.

HTTP Clone:
https://gitfoss.dev/ethicdevs/gitfoss.git
SSH Clone:
git@gitfoss.dev:ethicdevs/gitfoss.git

Branches:main, master.

Tags:v0.2.0,

GitFOSS • v0.2.0 (#7b50ebe) • MIT License