···99 // "features": {},
10101111 // Use 'forwardPorts' to make a list of ports inside the container available locally.
1212- "forwardPorts": [5700,5800]
1212+ "forwardPorts": [5858,5757]
13131414 // Use 'postCreateCommand' to run commands after the container is created.
1515 // "postCreateCommand": "yarn install",
+30-3
README.md
···11# tldraw for selfhosting
2233+[](https://opensource.org/licenses/MIT)
44+[](https://hub.docker.com/r/foxxmd/tldraw)
55+36A minimal implementation of [tldraw](https://tldraw.dev) based on the starter/templates [simple-sever](https://github.com/tldraw/tldraw/tree/main/templates/simple-server-example) and [sync-cloudflare](https://github.com/tldraw/tldraw/tree/main/templates/sync-cloudflare).
4758This implementation offers:
···13161417## Usage and tldraw License
15181616-When deployed on `localhost`, or when developing, this implementation is usable.
1919+[Docker image](https://hub.docker.com/r/foxxmd/tldraw) available at
2020+2121+```
2222+docker.io/foxxmd/tldraw:latest
2323+```
2424+2525+Use the [`compose.yaml`](/compose.yaml) docker compose file to start tldraw:
2626+2727+```
2828+docker compose up -d
2929+```
3030+3131+tldraw will be served at `http://localhost:5858`
3232+3333+## Production and tldraw License
17341818-If you deploy this to a valid TLD (`mydomain.com`) **you will need to provide a [license](https://tldraw.dev/community/license).** Hobby licenses, which are free, are available with application.
3535+When deployed on `localhost` with the above published image, or when developing with devcontainer, this implementation is usable.
19362020-To include your license you will need to build the image yourself: Add the build-arg `VITE_TLDRAW_LICENSE_KEY` or fill in using compose.yaml, then build.
3737+If you deploy tldraw-selfhosted to an SSL-enabled TLD (`https://mydomain.com`) then **you will need to build it with a valid tldraw [license](https://tldraw.dev/community/license).** Hobby licenses, which are free, are available by [applying on tldraw's site.](https://tldraw.dev/get-a-license/hobby)
3838+3939+To build the image with your license use [`compose.build.yaml`](/compose.build.yaml) and provide your license to the build-arg `VITE_TLDRAW_LICENSE_KEY`.
4040+4141+```sh
4242+git clone https://github.com/FoxxMD/tldraw-selfhosted tldraw-selfhosted
4343+cd tldraw-selfhosted
4444+# fill in VITE_TLDRAW_LICENSE_KEY in compose.build.yaml, then...
4545+docker compose -f compose.build.yaml build
4646+docker compose -f compose.build.yaml up -d
4747+```
21482249## License
2350