Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .do/app.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: anzu
services:
- name: anzu-web
dockerfile_path: Dockerfile
http_port: 3200
instance_count: 1
instance_size_slug: basic-xxs # Smallest size for testing, user can scale up.
routes:
- path: /
envs:
- key: ENV
value: production
- key: MONGO_URL
value: ${db.DATABASE_URL}
- key: MONGO_NAME
value: ${db.NAME}
- key: REDIS_URL
value: ${cache.INTERNAL_URL}
- key: JWT_SECRET
type: SECRET
value: "CHANGEME" # IMPORTANT: Replace with a long, random string
- key: S3_ENDPOINT
value: "CHANGEME" # e.g., nyc3.digitaloceanspaces.com
- key: S3_ACCESS_KEY_ID
type: SECRET
value: "CHANGEME"
- key: S3_SECRET_ACCESS_KEY
type: SECRET
value: "CHANGEME"
- key: S3_BUCKET_NAME
value: "anzu-assets"
- key: S3_REGION
value: "us-east-1" # Or your bucket's region
- key: OAUTH_GOOGLE_CLIENT_ID
type: SECRET
value: "CHANGEME"
- key: OAUTH_GOOGLE_CLIENT_SECRET
type: SECRET
value: "CHANGEME"
- key: OAUTH_FACEBOOK_CLIENT_ID
type: SECRET
value: "CHANGEME"
- key: OAUTH_FACEBOOK_CLIENT_SECRET
type: SECRET
value: "CHANGEME"
- key: SMTP_HOST
value: "CHANGEME" # e.g., smtp.sendgrid.net
- key: SMTP_PORT
value: "587"
- key: SMTP_USERNAME
type: SECRET
value: "CHANGEME"
- key: SMTP_PASSWORD
type: SECRET
value: "CHANGEME"
- key: SMTP_FROM_EMAIL
value: "CHANGEME" # e.g., no-reply@yourdomain.com
databases:
- name: db
engine: MONGO
- name: cache
engine: REDIS
66 changes: 66 additions & 0 deletions .do/deploy.template.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
spec:
name: anzu
services:
- name: anzu-web
git:
repo_clone_url: https://github.com/tryanzu/anzu.git
branch: main
dockerfile_path: Dockerfile
http_port: 3200
instance_count: 1
instance_size_slug: basic-xxs # Smallest size for testing, user can scale up.
routes:
- path: /
envs:
- key: ENV
value: production
- key: MONGO_URL
value: ${db.DATABASE_URL}
- key: MONGO_NAME
value: ${db.NAME}
- key: REDIS_URL
value: ${cache.INTERNAL_URL}
- key: JWT_SECRET
type: SECRET
value: "CHANGEME" # IMPORTANT: Replace with a long, random string
- key: S3_ENDPOINT
value: "CHANGEME" # e.g., nyc3.digitaloceanspaces.com
- key: S3_ACCESS_KEY_ID
type: SECRET
value: "CHANGEME"
- key: S3_SECRET_ACCESS_KEY
type: SECRET
value: "CHANGEME"
- key: S3_BUCKET_NAME
value: "anzu-assets"
- key: S3_REGION
value: "us-east-1" # Or your bucket's region
- key: OAUTH_GOOGLE_CLIENT_ID
type: SECRET
value: "CHANGEME"
- key: OAUTH_GOOGLE_CLIENT_SECRET
type: SECRET
value: "CHANGEME"
- key: OAUTH_FACEBOOK_CLIENT_ID
type: SECRET
value: "CHANGEME"
- key: OAUTH_FACEBOOK_CLIENT_SECRET
type: SECRET
value: "CHANGEME"
- key: SMTP_HOST
value: "CHANGEME" # e.g., smtp.sendgrid.net
- key: SMTP_PORT
value: "587"
- key: SMTP_USERNAME
type: SECRET
value: "CHANGEME"
- key: SMTP_PASSWORD
type: SECRET
value: "CHANGEME"
- key: SMTP_FROM_EMAIL
value: "CHANGEME" # e.g., no-reply@yourdomain.com
databases:
- name: db
engine: MONGO
- name: cache
engine: REDIS
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ Whether you're building a gaming community, developer forum, or general discussi

> ⚠️ **Early Development**: Anzu is in active development. While functional, the API and features may change significantly.

## 🚀 Deploy to DigitalOcean

You can deploy Anzu to the DigitalOcean App Platform with a single click.

[![Deploy to DigitalOcean](https://www.deploytodo.com/do-btn-blue.svg)](https://cloud.digitalocean.com/apps/new?repo=https://github.com/tryanzu/anzu/tree/main)

After deployment, you will need to configure the environment variables in the DigitalOcean App Platform dashboard. See the [Environment Variables](#-environment-variables) section below for more details.

## 🛠️ Tech Stack

- **Backend**: [Go 1.23+](https://golang.org/) with dependency injection
Expand Down Expand Up @@ -186,6 +194,31 @@ We appreciate your help in making Anzu better! If you have questions, feel free
- **Discussions**: Join community discussions and get help
- **Wiki**: Additional documentation and guides (coming soon)

### Environment Variables

When deploying to DigitalOcean, you will need to configure the following environment variables in the App Platform dashboard.

| Variable | Type | Required | Description |
| ----------------------------- | -------- | -------- | ------------------------------------------------------------------------------------------------------- |
| `JWT_SECRET` | `Secret` | Yes | A long, random string used to sign JWT tokens. |
| `S3_ENDPOINT` | `String` | Yes | The endpoint for your S3-compatible storage (e.g., `nyc3.digitaloceanspaces.com`). |
| `S3_ACCESS_KEY_ID` | `Secret` | Yes | The access key for your S3-compatible storage. |
| `S3_SECRET_ACCESS_KEY` | `Secret` | Yes | The secret key for your S3-compatible storage. |
| `S3_BUCKET_NAME` | `String` | Yes | The name of the S3 bucket to use for asset storage. |
| `S3_REGION` | `String` | Yes | The region where your S3 bucket is located. |
| `OAUTH_GOOGLE_CLIENT_ID` | `Secret` | No | The client ID for Google OAuth. |
| `OAUTH_GOOGLE_CLIENT_SECRET` | `Secret` | No | The client secret for Google OAuth. |
| `OAUTH_FACEBOOK_CLIENT_ID` | `Secret` | No | The client ID for Facebook OAuth. |
| `OAUTH_FACEBOOK_CLIENT_SECRET`| `Secret` | No | The client secret for Facebook OAuth. |
| `SMTP_HOST` | `String` | No | The hostname of your SMTP server. |
| `SMTP_PORT` | `String` | No | The port of your SMTP server. |
| `SMTP_USERNAME` | `Secret` | No | The username for your SMTP server. |
| `SMTP_PASSWORD` | `Secret` | No | The password for your SMTP server. |
| `SMTP_FROM_EMAIL` | `String` | No | The email address to send emails from. |
| `NEW_RELIC_KEY` | `Secret` | No | Your New Relic license key for application monitoring. |
| `NEW_RELIC_NAME` | `String` | No | The name of your application in New Relic. |
| `SENTRY_URL` | `Secret` | No | The DSN for Sentry error tracking. |

---

<div align="center">
Expand Down
Loading