···11-# Knot Docker
11+# RecapTime.dev Knot Server on Nest
2233-> **IMPORTANT**
44-> This is a community maintained repository, support is not guaranteed.
55-66-Docker container and compose setup to run a [Tangled](https://tangled.org) knot
77-and host your own repository data.
88-99-## Pre-built Images
1010-1111-There is a [repository](https://hub.docker.com/r/tngl/knot) of pre-built images
1212-for tags starting at `v1.8.0-alpha` if you prefer.
1313-1414-```
1515-docker pull tngl/knot:v1.10.0-alpha
1616-```
1717-1818-Note that these are *not* official images, you use them at your own risk.
33+This is a knot server that Recap Time Squad uses to host our Git repositories on
44+[Tangled](https://tangled.org), hosted on [Nest](https://hackclub.app) for the
55+Hack Club community.
1962020-## Building The Image
2121-2222-By default the `Dockerfile` will build the latest tag, but you can change it
2323-with the `TAG` build argument.
2424-2525-```sh
2626-docker build -t knot:latest --build-arg TAG=master .
2727-```
2828-2929-The command above for example will build the latest commit on the `master`
3030-branch.
3131-3232-By default it will also create a `git` user with user and group ID 1000:1000,
3333-but you can change it with the `UID` and `GID` build arguments.
3434-3535-```sh
3636-docker build -t knot:latest --build-arg UID=$(id -u) GID=$(id -g)
3737-```
3838-3939-The command above for example will create a user with the host user's UID and GID.
4040-This is useful if you are bind mounting the repositories and app folder on the host,
4141-as in the provided `docker-compose.yml` file.
77+## Usage
4284343-<hr style="margin-bottom: 20px; margin-top: 10px" />
99+On the repository creation page, select `knot.hackclub.community` as the Knot server.
1010+When cloning or adding/updating remote URLs, use the following SSH Git URLs below as documented:
44114545-When using compose, these can be specified as build arguments which will be
4646-passed to the builder.
1212+```bash
1313+git remote add origin ssh://git@knot.hackclub.community:33939/handle.host.tld/repo
47144848-```yaml
4949-build:
5050- context: .
5151- args:
5252- TAG: master
5353- UID: 1000
5454- GID: 1000
1515+# directly with Nest's hostname (since it's just a CNAME DNS record)
1616+git remote add origin ssh://git@hackclub.app:33939/handle.host.tld/repo
5517```
56185757-This will for example tell docker to build it using the `master` branch like
5858-the command.
1919+## Requesting access
59206060-## Setting Up The Image
2121+> You'll be asked for your AT Proto handle/DID PLC to provision access. Don't have one?
2222+> You can sign up via [Bluesky Social](https://bsky.app) or in [Tangled](https://tangled.org/signup)
2323+> directly.
61246262-The simplest way to set up your own knot is to use the provided compose file
6363-and run the following:
2525+Hack Clubbers can request access by contacting Andrei Jiroh in the Slack, either
2626+[via DMs](https://hackclub.slack.com/team/U07CAPBB9B5) or at the
2727+[main `#recaptime-dev` Slack channel](https://hackclub.slack.com/archives/C07H1R2PW9W).
64286565-```sh
6666-export KNOT_SERVER_HOSTNAME=example.com
6767-export KNOT_SERVER_OWNER=did:plc:yourdidgoeshere
6868-export KNOT_SERVER_PORT=443
6969-docker compose up -d
7070-```
2929+## Upstream docs
71307272-This will setup everything for you including a reverse proxy.
3131+* Knot hosting guide: https://tangled.org/tangled.org/core/blob/main/docs/knot-hosting.md
3232+* Docker-based setup: https://tangled.org/tangled.org/knot-docker/blob/main/readme.md