Skip to content

Commit

Permalink
docs: add self-hosting guide
Browse files Browse the repository at this point in the history
  • Loading branch information
boywithkeyboard committed Apr 11, 2024
1 parent 1091ff9 commit 73b7757
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,24 @@ import { crypto } from 'https://deno.re/denoland/[email protected]/crypto/mod.ts'

The order of priority for file extensions can be found [here](https://github.com/boywithkeyboard/deno.re/blob/main/registry/get_entry_point.ts#L6).

## Self-Hosting

There are two approaches you can take to deploy your custom instance of deno.re.

You can either

1. use our [Docker image](https://github.com/boywithkeyboard/deno.re/pkgs/container/deno.re)
2. or clone the repository and run `npm ci && npm run build` to build the server

Either way, you need to set the below environment variables in order for the server to work:

- `BASE_URL` *(The base URL for your custom instance, e.g. `https://foo.com`)*
- `S3_HOSTNAME` *(The public hostname of your bucket, e.g. `bar.foo.com`)*
- `S3_ACCESS_KEY_ID`
- `S3_SECRET_ACCESS_KEY`
- `S3_BUCKET` *(The name of your S3 bucket, e.g. `foo`)*
- `S3_ENDPOINT` *(e.g. `https://<id>.eu.r2.cloudflarestorage.com` for Cloudflare R2)*

## Terms of Use

deno.re is designed to be a permanent caching layer for Deno modules stored on GitHub. If you decide to abuse our service in whatever way, we reserve the right to blacklist your GitHub account.
Expand Down

0 comments on commit 73b7757

Please sign in to comment.