Skip to content

Commit ca4aba3

Browse files
authored
Merge pull request #127 from cori/add-obico
feat: add Obico self-hosted 3D printer management app
2 parents b7e13d8 + 1defed5 commit ca4aba3

4 files changed

Lines changed: 204 additions & 0 deletions

File tree

‎apps/obico/config.json‎

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
{
2+
"$schema": "../app-info-schema.json",
3+
"name": "Obico",
4+
"id": "obico",
5+
"available": true,
6+
"short_desc": "Self-hosted AI 3D printer remote management and failure detection",
7+
"author": "Obico (prebuilt images by gabe565/docker-obico)",
8+
"port": 3334,
9+
"categories": ["utilities"],
10+
"description": "Obico is an open-source platform for remotely monitoring and managing 3D printers, with machine-learning failure detection, timelapses, and a companion mobile app. This app wraps the official obico-server using prebuilt images from gabe565/docker-obico (which tracks the upstream release branch). Services: Django web UI + websocket server (port 3334), Celery task worker, ML API, and Redis (SQLite for the database). After install: add the Django site via django-admin or 'manage.py site --add <SITE_DOMAIN>', then link printers with Obico for Klipper (moonraker-obico) or Obico for OctoPrint. Form fields: SITE_DOMAIN (public hostname, used for CSRF_TRUSTED_ORIGINS and SITE_USES_HTTPS), DJANGO_SECRET_KEY (auto-generated), optional SMTP settings for email notifications.",
11+
"tipi_version": 2,
12+
"version": "release-7e02e29",
13+
"source": "https://github.com/TheSpaghettiDetective/obico-server",
14+
"website": "https://www.obico.io",
15+
"exposable": true,
16+
"supported_architectures": ["arm64", "amd64"],
17+
"created_at": 1792984565078,
18+
"updated_at": 1792984565078,
19+
"dynamic_config": true,
20+
"form_fields": [
21+
{
22+
"type": "text",
23+
"label": "Site Domain",
24+
"hint": "Public hostname of this Obico server (set as CSRF_TRUSTED_ORIGINS; SITE_USES_HTTPS=True). Must match the dashboard domain, e.g. obico.407.lol",
25+
"required": true,
26+
"env_variable": "SITE_DOMAIN",
27+
"default": "obico.407.lol"
28+
},
29+
{
30+
"type": "random",
31+
"label": "Django Secret Key",
32+
"hint": "Django secret key for cryptographic signing (auto-generated)",
33+
"required": true,
34+
"env_variable": "DJANGO_SECRET_KEY",
35+
"encoding": "hex"
36+
},
37+
{
38+
"type": "text",
39+
"label": "SMTP Host",
40+
"hint": "Optional. Mail server hostname for notification emails (leave blank to disable outbound email)",
41+
"required": false,
42+
"env_variable": "EMAIL_HOST",
43+
"default": ""
44+
},
45+
{
46+
"type": "number",
47+
"label": "SMTP Port",
48+
"hint": "Optional. Mail server port (587 with TLS is typical)",
49+
"required": false,
50+
"env_variable": "EMAIL_PORT",
51+
"default": 587
52+
},
53+
{
54+
"type": "text",
55+
"label": "SMTP User",
56+
"hint": "Optional. Mail account username",
57+
"required": false,
58+
"env_variable": "EMAIL_HOST_USER",
59+
"default": ""
60+
},
61+
{
62+
"type": "password",
63+
"label": "SMTP Password",
64+
"hint": "Optional. Mail account password",
65+
"required": false,
66+
"env_variable": "EMAIL_HOST_PASSWORD"
67+
},
68+
{
69+
"type": "text",
70+
"label": "From Email",
71+
"hint": "Optional. Sender address for notification emails",
72+
"required": false,
73+
"env_variable": "DEFAULT_FROM_EMAIL",
74+
"default": "changeme@example.com"
75+
}
76+
]
77+
}

‎apps/obico/docker-compose.json‎

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
{
2+
"$schema": "../dynamic-compose-schema.json",
3+
"schemaVersion": 2,
4+
"services": [
5+
{
6+
"name": "obico-redis",
7+
"image": "redis:7.2-alpine",
8+
"healthCheck": {
9+
"test": "redis-cli ping",
10+
"interval": "15s",
11+
"timeout": "5s",
12+
"retries": 10
13+
}
14+
},
15+
{
16+
"name": "obico-ml",
17+
"image": "ghcr.io/gabe565/obico/ml-api:sha-7e02e29",
18+
"command": "gunicorn --bind=0.0.0.0:3333 --workers=1 --access-logfile=- wsgi",
19+
"environment": [
20+
{ "key": "DEBUG", "value": "True" },
21+
{ "key": "FLASK_APP", "value": "server.py" }
22+
],
23+
"healthCheck": {
24+
"test": "wget --no-verbose --tries=1 --spider http://127.0.0.1:3333/hc/",
25+
"interval": "30s",
26+
"timeout": "10s",
27+
"retries": 10
28+
}
29+
},
30+
{
31+
"name": "obico-web",
32+
"image": "ghcr.io/gabe565/obico/web:sha-7e02e29",
33+
"isMain": true,
34+
"internalPort": 3334,
35+
"dependsOn": ["obico-redis", "obico-ml"],
36+
"command": "sh -c 'python manage.py migrate && python manage.py collectstatic --noinput --link && exec python manage.py runserver --noreload 0.0.0.0:3334'",
37+
"environment": [
38+
{ "key": "DEBUG", "value": "False" },
39+
{ "key": "DJANGO_SECRET_KEY", "value": "${DJANGO_SECRET_KEY}" },
40+
{ "key": "SITE_USES_HTTPS", "value": "True" },
41+
{ "key": "SITE_IS_PUBLIC", "value": "True" },
42+
{ "key": "CSRF_TRUSTED_ORIGINS", "value": "https://${SITE_DOMAIN}" },
43+
{ "key": "ACCOUNT_ALLOW_SIGN_UP", "value": "False" },
44+
{ "key": "WEBPACK_LOADER_ENABLED", "value": "False" },
45+
{ "key": "REDIS_URL", "value": "redis://obico-redis:6379" },
46+
{ "key": "DATABASE_URL", "value": "sqlite:////data/db.sqlite3" },
47+
{ "key": "INTERNAL_MEDIA_HOST", "value": "http://obico-web:3334" },
48+
{ "key": "ML_API_HOST", "value": "http://obico-ml:3333" },
49+
{ "key": "OCTOPRINT_TUNNEL_PORT_RANGE", "value": "0-0" },
50+
{ "key": "EMAIL_HOST", "value": "${EMAIL_HOST}" },
51+
{ "key": "EMAIL_PORT", "value": "${EMAIL_PORT}" },
52+
{ "key": "EMAIL_HOST_USER", "value": "${EMAIL_HOST_USER}" },
53+
{ "key": "EMAIL_HOST_PASSWORD", "value": "${EMAIL_HOST_PASSWORD}" },
54+
{ "key": "EMAIL_USE_TLS", "value": "True" },
55+
{ "key": "DEFAULT_FROM_EMAIL", "value": "${DEFAULT_FROM_EMAIL}" }
56+
],
57+
"volumes": [
58+
{ "hostPath": "${APP_DATA_DIR}/data", "containerPath": "/data" },
59+
{ "hostPath": "${APP_DATA_DIR}/media", "containerPath": "/app/static_build/media" },
60+
{ "hostPath": "${APP_DATA_DIR}/static", "containerPath": "/app/static_build" }
61+
],
62+
"healthCheck": {
63+
"test": "wget --no-verbose --tries=1 --spider http://127.0.0.1:3334/hc/",
64+
"interval": "30s",
65+
"timeout": "10s",
66+
"retries": 10
67+
}
68+
},
69+
{
70+
"name": "obico-tasks",
71+
"image": "ghcr.io/gabe565/obico/web:sha-7e02e29",
72+
"dependsOn": ["obico-web", "obico-redis", "obico-ml"],
73+
"command": "celery --app=config worker --beat --loglevel=info --concurrency=2 --queues=realtime,celery --schedule=/tmp/celerybeat-schedule",
74+
"environment": [
75+
{ "key": "DEBUG", "value": "False" },
76+
{ "key": "DJANGO_SECRET_KEY", "value": "${DJANGO_SECRET_KEY}" },
77+
{ "key": "SITE_USES_HTTPS", "value": "True" },
78+
{ "key": "SITE_IS_PUBLIC", "value": "True" },
79+
{ "key": "CSRF_TRUSTED_ORIGINS", "value": "https://${SITE_DOMAIN}" },
80+
{ "key": "ACCOUNT_ALLOW_SIGN_UP", "value": "False" },
81+
{ "key": "WEBPACK_LOADER_ENABLED", "value": "False" },
82+
{ "key": "REDIS_URL", "value": "redis://obico-redis:6379" },
83+
{ "key": "DATABASE_URL", "value": "sqlite:////data/db.sqlite3" },
84+
{ "key": "INTERNAL_MEDIA_HOST", "value": "http://obico-web:3334" },
85+
{ "key": "ML_API_HOST", "value": "http://obico-ml:3333" },
86+
{ "key": "OCTOPRINT_TUNNEL_PORT_RANGE", "value": "0-0" },
87+
{ "key": "EMAIL_HOST", "value": "${EMAIL_HOST}" },
88+
{ "key": "EMAIL_PORT", "value": "${EMAIL_PORT}" },
89+
{ "key": "EMAIL_HOST_USER", "value": "${EMAIL_HOST_USER}" },
90+
{ "key": "EMAIL_HOST_PASSWORD", "value": "${EMAIL_HOST_PASSWORD}" },
91+
{ "key": "EMAIL_USE_TLS", "value": "True" },
92+
{ "key": "DEFAULT_FROM_EMAIL", "value": "${DEFAULT_FROM_EMAIL}" }
93+
],
94+
"volumes": [
95+
{ "hostPath": "${APP_DATA_DIR}/data", "containerPath": "/data" },
96+
{ "hostPath": "${APP_DATA_DIR}/media", "containerPath": "/app/static_build/media" }
97+
]
98+
}
99+
]
100+
}

‎apps/obico/metadata/description.md‎

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Obico (self-hosted)
2+
3+
Open-source smart 3D printing platform: remote monitor and control your printers from your LAN or the Obico mobile app, with AI failure detection, timelapses, and push notifications — all on your own server.
4+
5+
This Runtipi app runs the official [Obico server](https://github.com/TheSpaghettiDetective/obico-server) using prebuilt images from [gabe565/docker-obico](https://github.com/gabe565/docker-obico), which tracks the upstream release branch.
6+
7+
## Services
8+
9+
- **web** — Django web UI + websocket gateway (port 3334)
10+
- **tasks** — Celery worker for timelapses, notifications, print handling
11+
- **ml-api** — machine-learning failure detection (Darknet/ONNX model)
12+
- **redis** — message broker and state cache
13+
14+
Data (SQLite DB, G-code, timelapses, static assets) persists under the app's data directory.
15+
16+
## Post-install steps
17+
18+
1. Add the Django site: `docker exec <obico-web-container> python manage.py site --add <your-domain>:443` and remove the default `localhost:3334` site (Django admin at `/admin/sites/site/`).
19+
2. Log in at `/admin/` with the default superuser `root@example.com` and change its password immediately.
20+
3. Link printers: install **Obico for Klipper** (`moonraker-obico`) on each Klipper printer (e.g. the Qidi Plus4) or the **Obico for OctoPrint** plugin, then link by discovery or one-time passcode.
21+
4. Point the Obico mobile app to your server URL to use it instead of the cloud.
22+
23+
## Notes
24+
25+
- Email notifications require the optional SMTP form fields; without them, notification emails are disabled (push via the mobile app still works).
26+
- `SITE_USES_HTTPS=True` and CSRF origins are set from the Site Domain field — keep it in sync with the dashboard domain.
27+
- ML failure detection runs locally in the ml-api container (CPU); no GPU required, but inference is faster with one.

‎apps/obico/metadata/logo.jpg‎

4.5 KB
Loading

0 commit comments

Comments
 (0)