ARSnova is a microservice-based system which usually would not be easy to setup for development.
To simplify the setup, pdk
is available, a script which generates a Docker Compose configuration based on templates.
Furthermore, pdk
is used to manage the containerized services.
-
CPU: 6 Cores or vCPU
-
RAM: 16 GiB
-
Storage: 10 GiB for Docker images and containers, additional storage for volumes containing user data depends on usage
-
Linux (see https://docs.docker.com/engine/install/#server for availability of official Docker packages)
-
Docker Engine >= 20.10 (older versions might work but are not tested for compatibility)
-
Docker Compose >= 2.0
-
Visual Studio Code
-
Clone this repository.
-
Switch to the repository’s root directory and run
./pdk update
. -
Run
./pdk
to list all available commands.
To work with the development environment you first need to start it:
./pdk run -d
This starts all service containers. On the first run, it will create Devcontainer images for the services of this repository.
The images use the prebuilt versions of the application from a base image. This allows way, you have a completely functional system without building services which you are not working on. The version of the base image for each service can be changed:
./pdk tags
For development, the prebuilt service needs to replaced with a development server.
When you open the subproject in Visual Studio Code (./pdk open <project>
), the prebuild service is stopped automatically.
You can then launch the application from VS Code.
If you prefer to use another IDE, you can launch a development server independently from VS Code:
./pdk dev-server <project>
This also stops the prebuild service and runs the bootRun
Gradle task for Spring projects.
Non-Spring-based projects are currently not supported by the dev-server
command.
The pdk
script supports the following commands:
|
Start Devcontainers for all services. |
|
Starts a development server. |
|
Open project in Devcontainer with Visual Studio Code. |
|
Set the image tags of projects to use with Docker Compose. |
|
Show logs or the log for a specific service. |
|
Execute a Docker Compose command. |
|
Update Git repositories, Docker Compose configuration, Devcontainers and the Gradle dependency cache. |
|
Update the configuration for Docker Compose. This command is automatically run when needed. |
|
(Re-)build Devcontainers. This command is automatically run when needed. |
-
No prebuilt version of the webclient is launched when running
./pdk run
. It currently needs to be launched from VS Code. -
At this time, there is no mature VS Code plugin for Kotlin support. The plugin currently used for the devcontainers of Kotlin-based services has grave performance issues. Therefore, the use of another IDE is recommended for Kotlin development. A development server can be started with the
dev-server
command.