Packages a JHipster application into a debian/ubuntu .deb package
npm install generator-jhipster-debian-packagerThis is a JHipster module, that is meant to be used in a JHipster application.
The module uses the jdeb library to repackage the war and configuration files into a .deb archive
As this is a JHipster module, we expect you have JHipster and its related tools already installed:
To install this module:
``bash`
npm install -g generator-jhipster-debian-packager
To update this module:
`bash`
npm update -g generator-jhipster-debian-packager
In your JHipster project directory run:
`bash`
yo jhipster-debian-packager`
This will add a jdeb goal to the pom.xml and support files that will create a .deb archive in the target directory when mvn package` is called.`
Options :
* --force` if you don't want questions to be asked.`
* --clean` to uninstall the module instead of installing.
NOTE: with the current version of JHipster, some modifications must be done manually in the pom.xml:
* upgrade Spring Boot version to 1.3.2.RELEASE (because of issue https://github.com/spring-projects/spring-boot/issues/4866)
* with JHipster version <= 2.26.2, set the war as executable for the prod profile with ``
You can then use the command
`bash`
dpkg-i target/myapp_0.0.1~SNAPSHOT_all.deb
to install the package on a debian or ubuntu server. Or you can deploy it to an apt repository.
The executable war will be installed and started as a linux service. To start it manually use:
`bash`
sudo service `
By default, the application is started with the prod` profile. This can be changed in the `/etc/default/` configuration file.
The package installs the following files:
* `/usr/share/`: your JHipster application as executable war symlinked to `/usr/share/``
* /etc/default/`: the launch script configuration file (see Spring Boot doc. The .conf file is symlinked to this file)`
* /etc/`: the directory for the configuration files (application.yml, ...)`
* /var/log/`` : the directory for the application logs
Apache-2.0 © [Christophe Bornet]
[npm-image]: https://img.shields.io/npm/v/generator-jhipster-debian-packager.svg
[npm-url]: https://npmjs.org/package/generator-jhipster-debian-packager
[travis-image]: https://travis-ci.org/cbornet/generator-jhipster-debian-packager.svg?branch=master
[travis-url]: https://travis-ci.org/cbornet/generator-jhipster-debian-packager
[daviddm-image]: https://david-dm.org/cbornet/generator-jhipster-debian-packager.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/cbornet/generator-jhipster-module