Skip to content

Commit 9ae5be4

Browse files
authored
Merge pull request #11 from coder/fix-railway
fix: use external database in railway
2 parents 0ae970e + 36ca082 commit 9ae5be4

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

railway/Dockerfile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,7 @@ ENV PORT=3000
33
ENV CODER_HTTP_ADDRESS=0.0.0.0:$PORT
44
ARG RAILWAY_STATIC_URL=
55
ENV CODER_ACCESS_URL=https://$RAILWAY_STATIC_URL
6+
ARG DATABASE_URL
7+
ENV CODER_PG_CONNECTION_URL=$DATABASE_URL
68
ENV CODER_EXPERIMENTS=*
79
ENV CODER_TELEMETRY_INSTALL_SOURCE=railway.app

railway/railway.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ https://railway.app/template/cUQ8_P?referralCode=tfH8Uw
1616

1717
The current version of the template allows you to set an optional environment variable `CODER_WILDCARD_ACCESS_URL` which will allow you to forward ports from your workspace to a custom wildcard subdomain of the URL you provide. This is useful if you want to access a service running in your workspace from a browser. For example, if you set `CODER_WILDCARD_ACCESS_URL` to `*.coder.example.com`, you can access a service running on port 8080 in your workspace by visiting `8080--app-name-workspace-name-.coder.example.com` in your browser.
1818

19-
> Note: This is an optional step. If you do not set this variable, you will not be able to access services running in your workspace from a browser. For more information. You have to use a custom domain with Railway and cannot use railway's built-in domain for this wildcard.
19+
> Note: This is an optional step. If you do not set this variable, you will not be able to access services running in your workspace from a browser. You have to use a custom domain with Railway and cannot use railway's built-in domain for this wildcard.
2020
2121
> Note: You can set environment variables by going to _Dashboard > Coder (Service) > Settings > Environment Variables_. See our [docs](https://coder.com/docs/v2/latest/cli/server) for more information on environment variables that can be set.
2222
@@ -28,19 +28,19 @@ Your Coder deployment will always be accessible at `https://app-name.up.railway.
2828

2929
Create your first user by going to `https://app-name.up.railway.app` or your custom domain.
3030

31-
![Welcome to Coder](https://raw.githubusercontent.com/coder/blogs/coder-on-railway/posts/coder-on-railway/static/coder_setup.png)
31+
![Welcome to Coder](https://raw.githubusercontent.com/coder/blogs/main/posts/coder-on-railway/static/coder_setup.png)
3232

3333
### 3. Create your first template
3434

3535
[**Templates**](https://coder.com/docs/v2/latest/templates): Templates are written in Terraform and describe the infrastructure for workspaces. Coder provides a set of starter templates to help you get started.
3636

3737
Choose a template to set up your first workspace. You can also [create your own templates](https://coder.com/docs/v2/latest/templates) to define your custom infrastructure with your preferred cloud provider.
38-
![starter templates](https://raw.githubusercontent.com/coder/blogs/coder-on-railway/posts/coder-on-railway/static/starter_templates_welcome.png)
38+
![starter templates](https://raw.githubusercontent.com/coder/blogs/main/posts/coder-on-railway/static/starter_templates_welcome.png)
3939

4040
### 4. Create your first workspace
4141

4242
[**Workspaces**](https://coder.com/docs/v2/latest/workspaces): Workspaces contain the IDEs, dependencies, and configuration information needed for software development. You can create workspaces from templates. Here wea are showing the workspaces created from the Fly.io starter template in action.
43-
![fly.io workspace](https://raw.githubusercontent.com/coder/blogs/coder-on-railway/posts/coder-on-railway/static/fly_workspace.png)
43+
![fly.io workspace](https://raw.githubusercontent.com/coder/blogs/main/posts/coder-on-railway/static/fly_workspace.png)
4444

4545
- [**Coder on GitHub**](https://github.com/coder/coder)
4646
- [**Coder docs**](https://coder.com/docs/v2)

0 commit comments

Comments
 (0)