Hydra Order Management System
Ruby CoffeeScript HTML CSS JavaScript Shell Dockerfile
Clone or download
sugarfree1 Merge pull request #144 from latera/HOMS-206
HOMS-206 Update Capybara and search table rows by xpath
Latest commit c05d8c3 Jul 20, 2018
Permalink
Failed to load latest commit information.
app HOMS-207 Permit all parameters by default Jul 19, 2018
bin Initial commit Apr 27, 2016
config HOMS-207 Permit all parameters by default Jul 19, 2018
db Update migrations for Rails 5.1.6 Jul 11, 2018
fixtures/order_types HOMS-104 Add printform code to order type, add printform code to test… Jul 13, 2016
hbw HOMS-207 Permit all parameters by default Jul 19, 2018
lib FEAT-327 Move minio to hbw May 23, 2018
public Initial commit Apr 27, 2016
spec Merge pull request #144 from latera/HOMS-206 Jul 20, 2018
vendor/assets HOMS-155 Add profiles for order list display settings Feb 26, 2018
.gitignore HOMS-194 Change docker DB data volume path May 30, 2018
.rspec Initial commit Apr 27, 2016
.rubocop.yml Initial commit Apr 27, 2016
Dockerfile Install wget to test Docker image Jul 19, 2018
Dockerfile.oracle Merge branch 'master' into HOMS-200 Jul 17, 2018
Dockerfile.production HOMS-195 Run tests in docker Jun 6, 2018
Dockerfile.test Install wget to test Docker image Jul 19, 2018
Gemfile Update Ruby from 2.3.6 to 2.5.1 (#137) Jul 12, 2018
Gemfile.lock HOMS-206 Update Capybara and search table rows by xpath Jul 20, 2018
INSTALL.md Update Ruby from 2.3.6 to 2.5.1 (#137) Jul 12, 2018
LICENSE Initial commit Apr 27, 2016
README.md HOMS-205 Add minio container to docker-compose Jul 3, 2018
Rakefile Initial commit Apr 27, 2016
config.ru Initial commit Apr 27, 2016
docker-compose.dev.oracle.yml HOMS-205 Add minio container to docker-compose Jul 3, 2018
docker-compose.dev.yml HOMS-205 Add minio container to docker-compose Jul 3, 2018
docker-compose.test.yml HOMS-197 Remove sed from homs entrypoint Jun 19, 2018
docker-compose.yml HOMS-205 Add minio container to docker-compose Jul 3, 2018
entrypoint.sh HOMS-197 Remove sed from homs entrypoint Jun 19, 2018
run_tests.sh HOMS-206 Update Capybara and search table rows by xpath Jul 20, 2018
wait_for_postgres.sh HOMS-164 Add postgresql-client for check DB availability Feb 28, 2018

README.md

Hydra Order Management System (homs)

homs is an open source web application for order and business process management.

Application consists of three parts:

  • User interface - managing orders for registered users (Single Page Application).
  • Administrator interface - managing users and order types.
  • REST API - operations with orders and users.

Requirements:

Resources:

Installation

There are 2 ways to install HOMS.

Using docker

In production

  1. Install docker-compose.
  2. Download docker-compose.yml:
wget https://raw.githubusercontent.com/latera/homs-docker/master/docker-compose.yml
  1. For OS X users: make path to folder with HOMS shared in Docker -> Preferences... -> File Sharing.
  2. Copy your (or default) configs to /etc/hydra/homs/:
cp activiti.yml /etc/hydra/homs/activiti.yml
cp database.yml /etc/hydra/homs/database.yml
cp hbw.yml /etc/hydra/homs/hbw.yml
cp homs_configuration.yml /etc/hydra/homs/homs_configuration.yml
cp imprint.yml /etc/hydra/homs/imprint.yml
cp sources.yml /etc/hydra/homs/sources.yml
cp secrets.yml /etc/hydra/homs/secrets.yml
  1. Add environment variables: $HOMS_PATH with path to your HOMS folder and Minio credentials:
HOMS_PATH=/path/to/homs export HOMS_PATH
MINIO_ACCESS_KEY=minio_access_key_from_hbw_yml export MINIO_ACCESS_KEY
MINIO_SECRET_KEY=minio_secret_key_from_hbw_yml export MINIO_SECRET_KEY
  1. Run docker-compose:
docker-compose up -d

Login at http://localhost:3000 with user@example.com/changeme.

In development

If you don't want to use Oracle as source for your HOMS instance:

Without Oracle Instant Client
  1. Clone HOMS git repository:
git clone https://github.com/latera/homs.git
  1. Make configs from samples:
find config -name '*.sample' | xargs -I{} sh -c 'cp $1 ${1%.*}' -- {}
  1. Install docker-compose.
  2. For OS X users: make path to folder with HOMS shared in Docker -> Preferences... -> File Sharing.
  3. Add test environment to config/database.yml:
development:
  adapter: postgresql
  encoding: unicode
  pool: 5
  host: postgres-homs
  database: homs
  username: homs
  password: homs
  1. Add to config/sources.yml
sources:
  bpmanagementsystem:
    type: static/activiti
  1. Add environment variables: $HOMS_PATH with path to your HOMS folder and Minio credentials:
HOMS_PATH=/path/to/homs export HOMS_PATH
MINIO_ACCESS_KEY=minio_access_key_from_hbw_yml export MINIO_ACCESS_KEY
MINIO_SECRET_KEY=minio_secret_key_from_hbw_yml export MINIO_SECRET_KEY
  1. Run docker-compose:
docker-compose -f docker-compose.dev.yml up -d

Login at http://localhost:3000 with user@example.com/changeme.

Or if you want to use Oracle as source for your HOMS instance

With Oracle Instant Client

Steps 1 – 5 are the same as for without Oracle Instant Client installation

  1. Download the Oracle Instant Client 11.2 archives from OTN:

http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html

The following three ZIPs are required:

  • instantclient-basic-linux.x64-11.2.0.4.0.zip
  • instantclient-sdk-linux.x64-11.2.0.4.0.zip
  • instantclient-sqlplus-linux.x64-11.2.0.4.0.zip
  1. Place the downloaded Oracle Instant Client RPMs in the same directory as the Dockerfile and run:
docker build -t latera/homs-with-oracle -f Dockerfile.oracle .
  1. Add to config/sources.yml
sources:
  bpmanagementsystem:
    type: static/activiti
  billing:
    type: sql/oracle
    tns_name: dbname
    username: user
    password: password
  1. Add environment variables: $HOMS_PATH with path to your HOMS folder, $TNSNAMES_PATH with path to your tnsnames.ora file and Minio credentials:
HOMS_PATH=/path/to/homs export HOMS_PATH
TNSNAMES_PATH=/path/to/tnsnames.ora export TNSNAMES_PATH
MINIO_ACCESS_KEY=minio_access_key_from_hbw_yml export MINIO_ACCESS_KEY
MINIO_SECRET_KEY=minio_secret_key_from_hbw_yml export MINIO_SECRET_KEY

for access to host machine OS X users can use special DNS name host.docker.internal as host in tnsnames.ora (details)

  1. Run docker-compose:
docker-compose -f docker-compose.dev.oracle.yml up -d

Login at http://localhost:3000 with user@example.com/changeme.

Using manual installation instruction

Contributing/Development

The general development process is:

  1. Fork this repo and clone it to your workstation.
  2. Create a feature branch for your change.
  3. Write code and tests.
  4. Push your feature branch to github and open a pull request against master.

Reporting Issues

Issues can be reported by using GitHub Issues.

Testing

homs uses RSpec for unit/spec tests. You need to set up different testing database. Otherwise your development DB would be erased.

# Run all tests
bundle exec rspec spec

# Run a single test file
bundle exec rspec spec/PATH/TO/FILE_spec.rb

# Run a subset of tests
bundle exec rspec spec/PATH/TO/DIR

License

Copyright (c) 2016 Latera LLC under the Apache License.