Skip to content

Updating The Onboarding Process#158

Merged
jampukka merged 2 commits intonlsfi:mainfrom
EricLo-417:features/quick-start_elomonaco
Oct 21, 2025
Merged

Updating The Onboarding Process#158
jampukka merged 2 commits intonlsfi:mainfrom
EricLo-417:features/quick-start_elomonaco

Conversation

@EricLo-417
Copy link
Contributor

I added a docker folder that can be used to quickly get started with development. This will create a new database; auto run the needed init scripts and create needed tables. It will also run the application in a tomcat docker image

I also added an option to run the application with hot reload for quicker smoother development. The image side is a little janky but it mostly uses the same base image but downloads JDK that has DCEVM as well as downloads hotswap-agent.jar.
The docker compose file will then run the application with the correct config. From there all you need to do is connect to the container from your IDE (I only have IntelliJ so that's what I tested with). Now whenever you make code changes you can hot-reload those classes without all the normal annoyance with tomcat deployments.

@jampukka
Copy link
Collaborator

Great, thanks!

@jampukka jampukka merged commit 7a5ac1c into nlsfi:main Oct 21, 2025
3 checks passed
@jampukka
Copy link
Collaborator

Had an issue with mvn package in Dockerfile-hotreload not having access to my local maven repository containing the installed hakunapi packages causing the whole thing to fail. I added -am to circumvent the issue which didn't feel like the best thing to do but it worked.

@jampukka
Copy link
Collaborator

Remote Debugging with VSCode add following configuration to .vscode/launch.json '.configurations[]'

    {
        "type": "java",
        "name": "Remote Debug - Hakunapi",
        "request": "attach",
        "hostName": "localhost",
        "port": 41467,
        "projectName": "hakunapi"
    }

(have to add this to readme...)

@EricLo-417
Copy link
Contributor Author

Had an issue with mvn package in Dockerfile-hotreload not having access to my local maven repository containing the installed hakunapi packages causing the whole thing to fail. I added -am to circumvent the issue which didn't feel like the best thing to do but it worked.

Ah that makes sense....

I think a better solution is probably just building the whole repo at that stage mvn -DskipTests clean package... it does make take a much longer time building the image with all the pom dep downloads

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants