Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

generator-jhipster-docker

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

generator-jhipster-docker

Additional Docker support: Docker Hub, Local SMTP Server, NGinx

  • 2.5.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
261
increased by71.71%
Maintainers
1
Weekly downloads
 
Created
Source

generator-jhipster-docker

NPM version Build Status Dependency Status

JHipster module, additional Docker support in your JHipster application

Introduction

This is a JHipster module, that is meant to be used in a JHipster application. This module is used to generate a:

  • Dockerfile for Automated build at Docker Hub
  • Docker Compose file for using a Local SMTP Server with MailDev
  • Docker Compose file for using NGinx as proxy server

Table of contents

Prerequisites

As this is a JHipster module, we expect you have JHipster and its related tools already installed:

You have to install Docker and Docker Compose:

To use Automated build, you have to create an account at:

Installation

With Yarn

To install this module:

yarn global add generator-jhipster-docker

To update this module:

yarn global upgrade generator-jhipster-docker

With NPM

To install this module:

npm install -g generator-jhipster-docker

To update this module:

npm update -g generator-jhipster-docker

Usage

To run the module on a JHipster generated application:

yo jhipster-docker

You can use this command to generate the Dockerfile for Automated build:

yo jhipster-docker default

To force the generator:

yo jhipster-docker default --force

1 - Automated build at the Docker Hub

1.1 - Description

When using the option Dockerfile for Automated build, Docker Hub will build a Docker image everytime you commit to your repository.

1.2 - Generate the files

  • Launch : yo jhipster-docker
  • Select the option : Dockerfile for Automated build at https://hub.docker.com/

1.3 - Set your Docker Hub project

At GitHub
  • Go to Settings > Integrations & services
  • Add service and select Docker
  • Click [x] active
  • Click on update service
  • Back to Integration & services, Docker must be :white_check_mark: Docker
At Docker Hub
  • Go to Build Settings
    • Choose your branch or let master by default
    • Put this Dockerfile location: /
    • Click on Save Changes
  • Return to this project: git commit and push these changes!
  • Go to Build details: it should be a new line with Building

2 - Local SMTP Server

The project djfarrelly/maildev is a simple way to test your project’s generated emails during development with an easy to use web interface.

You can launch:

docker-compose -f src/main/docker/smtp.yml up -d

You can access to it: http://localhost:1080

3 - NGinx as proxy server

See the official documentation

Follow these steps:

  • Start your local backend server or use an existing one. You can start more than 1 backend server.
  • Edit src/main/docker/nginx/nginx.conf, depending on the 1st step
  • Start NGinx:
docker-compose -f src/main/docker/nginx.yml up -d

Note: The use of network_mode: 'host' in nginx.yml may not work for Windows or MacOS. Simply comment it and replace localhost in src/main/docker/nginx/nginx.conf file. Your container (from inside) must access to the application.

You can access to it: http://localhost or http://localhost:8000

License

Apache-2.0 © Pascal Grimaud and the respective JHipster contributors

Keywords

FAQs

Package last updated on 08 Apr 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc