A collection of scripts to get a Kompakkt development environment up and running
Kompakkt is split up into multiple services, and getting all of them running locally can be a hassle. Mono tries to consolidate these services to get a development environment of Kompakkt running locally.
-
Clone this repository:
git clone https://github.com/Kompakkt/Mono.git cd Mono -
Make the script executable:
chmod +x kompakkt.ts
-
Run the setup command to clone all repositories and build the base image:
./kompakkt.ts setup
-
Start the environment:
./kompakkt.ts up
./kompakkt.ts setup- Clone repositories, create uploads directory, and build base Docker image./kompakkt.ts up- Start the Kompakkt environment./kompakkt.ts down- Stop the Kompakkt environment./kompakkt.ts pull- Pull the latest Docker images./kompakkt.ts compose [args]- Run Docker Compose with additional arguments
Once the environment is running, you can access the following services:
| Service | URL | Description |
|---|---|---|
| Kompakkt Repository | http://localhost:8080/ | Main repository interface |
| Kompakkt Viewer | http://localhost:8080/viewer/ | 3D viewer application |
| Kompakkt API | http://localhost:8080/server/ | Backend API |
| API Documentation | http://localhost:8080/server/swagger/ | Swagger API documentation |
| MailHog | http://localhost:8025/ | Email testing interface |
| MongoDB | localhost:37017 | MongoDB database (credentials in docker-compose.yml) |
The setup provides hot-reloading for the frontend applications:
- Repo code is mounted at
./Repo/ - Viewer code is mounted at
./Viewer/ - Server code is mounted at
./Server/ - Files uploaded to the platform are stored in
./uploads/
Any changes to the code in these directories will trigger automatic rebuilds thanks to the development servers.
- Server configuration is provided via
server-config.json - Environment settings for Angular applications are in
shared-environment.ts - Routing is handled by Caddy as defined in the
Caddyfile
If you encounter any issues:
-
Check logs for a specific service:
./kompakkt.ts compose logs [service-name]
-
Restart a specific service:
./kompakkt.ts compose restart [service-name]
-
Rebuild a service:
./kompakkt.ts compose up -d --build [service-name]
