Coder Social home page Coder Social logo

rhmi-solution-pattern-orders-management-ui's Introduction

RHMI Solution Pattern No. 1 Fuse Service

Purpose

This UI displays orders received and provides a facility to assign a user to the order.

Local Development

Requires:

  • Node.js 10+
  • npm 6+

Run the following commands from the frontend/ directory in this repository:

npm i
npm run start:dev

You can now access the application on http://localhost:8080

Development Deployment

Use npm run openshift to easily deploy this application on OpenShift.

Build an Image

source-to-image (s2i) is used to generate builds.

The commands are as follows once you have Docker and s2i installed:

export CONTAINER_NAME=rhmi-lab-order-management-ui
docker pull registry.access.redhat.com/ubi8/nodejs-10
s2i build . registry.access.redhat.com/ubi8/nodejs-10 $CONTAINER_NAME

Applying Keycloak / Red Hat SSO Protection

Start the server with the KEYCLOAK_CONFIG environment variable set to a valid JSON Object containing a Keycloak configuration. For example:

# You can get this from a client in keycloak
export KEYCLOAK_CONFIG='{"realm":"master","auth-server-url":"http://localhost:9090/auth","ssl-required":"external","resource":"orders-app","public-client":true,"confidential-port":0}'

# The server will automatically apply keycloak middleware using KEYCLOAK_CONFIG
npm run start:dev

If you need a Keycloak instance locally try the following:

  1. docker run -p 9090:9090 jboss/keycloak
  2. Access Keycloak at http://localhost:9090 when it's ready
  3. Login using the username admin and password admin
  4. Create a Client and set the Root URL to http://localhost:8080
  5. Ensure the Access Type for the client is set to public
  6. Create a Role named staff in this new client under the Roles tab
  7. Create a User with any name
  8. Choose User > Credentials and assign a password to the user
  9. Choose User > Role Mappings and select your Client from the Client Roles dropdown.
  10. Assign the staff role.

rhmi-solution-pattern-orders-management-ui's People

Contributors

evanshortiss avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.