Rails 8 + Tailwind + Solid
Database: sqlite3
There's no convention defined for the folder names you only need to keep the structure like this:
/courses
- /Course name # Main course folder
- /Unit 1 - Name # Unit folder
- lesson-1.mp4
- lesson-2.mp4
- /Second Unit Name
- lesson-1.mp4
docker buildx build -t nerijunior/self-hosted-course-platform:latest .
- Create the Rails secret key
- Set
YOUR_DOWNLOADED_COURSES_PATHto the place where you organized your courses - Set
SOLID_QUEUE_IN_PUMA=trueto avoid the need of a secondary container for background jobs - Set
rails/storagevolume to have access to sqlite and active_record files.
services:
cursos:
image: nerijunior/self-hosted-course-platform:latest
container_name: cursos
restart: unless-stopped
environment:
SECRET_KEY_BASE: ${SECRET_KEY_BASE} # generate using rails credentials:edit -e production
COURSES_PATH: /courses
SOLID_QUEUE_IN_PUMA: true
ports:
- "127.0.0.1:3000:3000"
volumes:
- /YOUR_DOWNLOADED_COURSES_PATH:/courses
- /home/{YOUR_USER}/servers/cursos/storage:/rails/storage
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:3000/up"]
interval: 30s
timeout: 10s
retries: 3