- install ruby on rails: http://www.installrails.com/
You can easily set up and run this project in a VS Code Devcontainer:
-
Open in VS Code/Cursor
- Make sure you have the Dev Containers extension installed.
- Open this project folder in VS Code.
- When prompted, reopen the folder in the devcontainer, or use the command palette:
Dev Containers: Reopen in Container.
-
Initial Setup
- The devcontainer will automatically build and run
bin/setup --skip-serverto install dependencies and prepare the database. - If you need to re-run setup, use:
bin/setup --skip-server
- The devcontainer will automatically build and run
-
Start the Rails Server
- In the devcontainer terminal, run:
bin/dev
- The app will be available at http://localhost:8080 on your host machine.
- In the devcontainer terminal, run:
- the devcontainer.json configuration will also copy your ssh settings for github to the docker container so you can use git without needing to reauthenticate
bin/docker-buildOr pass a custom tag:
bin/docker-build v1.0.0This tags the image as both draft:<tag> and draft:<git-sha>.
bin/docker-runThe app will be available at http://draft.localhost. To use a different port:
PORT=3001 bin/docker-runNamed volumes (draft-data and draft-storage) persist the database and uploaded files across container restarts.