generator-jhipster-yellowbricks-spring-boot-contextpath
v2.0.1
Published
JHipster blueprint to configure Spring Boot application context-path
Maintainers
Readme
generator-jhipster-yellowbricks-spring-boot-contextpath
One of - a JHipster blueprint that sets
server.servlet.context-path in application.yml to a configurable context path.
JHipster source
- Generator:
generators/spring-boot - Template:
application.yml.ejs
What it does
Patches src/main/resources/config/application.yml during generation to insert context-path as the first key in server.servlet:
server:
servlet:
+ context-path: /jh/
session:
cookie:
http-only: trueThe value is configurable — any context path can be used.
Prerequisites
- Node.js
^22.18.0 || >=24.11.0 - JHipster 9
Installation
npm install -g generator-jhipster-yellowbricks-spring-boot-contextpathUsage
Create a .yo-rc.json in your project directory with the desired context path:
{
"generator-jhipster-yellowbricks-spring-boot-contextpath": {
"contextPath": "/jh/"
}
}Then run JHipster with this blueprint:
# Standard generator
jhipster --blueprints yellowbricks-spring-boot-contextpath
# With JDL
jhipster import-jdl your-app.jdl --blueprints yellowbricks-spring-boot-contextpathReplace /jh/ with your actual context path. The trailing slash is required.
