summaryrefslogtreecommitdiff
path: root/content/forge/internals/_index.md
blob: 9d0029164c78a08a46d1bea57f9bebf3e692d37d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32

---
title: Internals
---

This section describes some of the internals of the forge.

It is not intended for end users or even system administrators, but only for
developers.

## Architecture

The **main forge daemon** handles HTTP requests, SSH connections, incoming
emails, IMAP access, the API, and just about anything that the user might
want to access. It connects to the PostgreSQL database for most of its data,
with the exception of Git repositories.

The **git2d** daemon is a separate process that handles all Git operations.
Currently, the forge daemon automatically deploys and starts this daemon
when it is started, and connects via UNIX domain sockets.
Note that git2d is currently incomplete, so the forge daemon uses go-git for
many operations.

Additionally, the main forge daemon currently launches instances of
git-receivv-pack and git-upload-pack for Git network operations. This will be
merged into git2d in the future.

In the future Git operations may be delegated to multiple nodes by using TCP
instead of UNIX domain sockets and by ensuring all Git operations happen
through git2d.

In the current architecture, git-receive-pack launches a pre-receive hook,
[hookc](hookc/).