• Stars
    star
    228
  • Rank 175,267 (Top 4 %)
  • Language Makefile
  • License
    GNU General Publi...
  • Created almost 7 years ago
  • Updated about 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Reaction Platform is the quickest way to run Reaction (reactioncommerce/reaction) and dependent services—Reaction Admin (reactioncommerce/reaction-admin) and Example Storefront (reactioncommerce/example-storefront)

NOTE: THIS PROJECT IS DEPRECATED

No further work is being done to maintain or improve this project

You should use the Reaction CLI to start working with the project

Consult the Open Commerce Quick Start Guide for more information

Overview

Reaction Platform is a customizable, real-time, reactive commerce solution. This repository is the quickest way to get started with the Reaction API and its supporting services in a local development environment.

Features

  • A modern, enterprise-ready, real-time commerce platform.
  • A microservices based architecture.
  • Docker based development environment.
  • Launched and configured with a single CLI command.

Prerequisites

  • GNU Make
    • MacOS and Linux users will have a suitable version bundled with the OS
  • Bourne Shell and POSIX tools (sh, grep, sed, awk, etc)
    • MacOS and Linux users will have a suitable version bundled with the OS
  • Git
  • Docker | Docker for Mac | Docker for Windows
  • A GitHub account with a configured SSH key is not required by default, but necessary when using custom, private Github repositories.

Getting started

Clone this repository, and then run make in the reaction-development-platform directory. If all goes well, it will take some time to download and start all of the components, but when it's done you'll have the entire Reaction application running on your computer through Docker. Individual services are cloned as child directories within this project.

git clone [email protected]:reactioncommerce/reaction-development-platform.git
cd reaction-development-platform
make

Behind the scenes make is

  • checking that dependencies are present
  • cloning sub-projects from GitHub
  • downloading Docker images
  • starting services

These services will be running when the initial make command is complete:

Service Description
Reaction API (http://localhost:3000) The Reaction API, which includes a GraphQL endpoint. See GraphQL Playground.
Reaction Admin (http://localhost:4080) A user interface for administrators and shop managers to configure shops, manage products, and process orders.
Example Storefront (http://localhost:4000) An example Reaction storefront UI built with Next.JS.

If the make command fails at some point, you can run or rerun it for specific services with:

make init-<project-name>

Example:

make init-example-storefront

Migrating from v3.x.x to v4.x.x

Look at the detailed guide here

Ongoing Support for v3.x

We'll continue to provide v3.x support for 6 months from the v4.0 release. That marks 3/1/2022 as the date when we officially end support to 3.x versions and below. Beyond that date we'll be fully dedicated to the new version and will not be taking any v3.x issues into discussion/development.

Project Commands

These are the available make commands in the reaction-platform root directory.

Command Description
make Bootstraps the entire Reaction development environment in Docker. Projects will use production Docker images and code.
make init-<project-name> Example: make init-example-storefront. Does clone/setup for a single project.
make init-dev Bootstraps the entire Reaction development environment in Docker. Projects will use development configuration.
make init-dev-<project-name> Example: make init-dev-example-storefront. Does clone/setup for a single project and configures it with a development configuration.
make stop Stops all containers.
make stop-<project-name> Example: make stop-example-storefront. Stops all containers for a single project.
make start Starts all containers.
make start-<project-name> Example: make start-example-storefront. Starts all containers for a single project.
make dev-<project-name> Example: make dev-example-storefront. Starts all containers for a single project in development mode.
make dev-link Creates docker-compose.override.yml symlinks for development in all projects.
make dev-link-<project-name> Example: make dev-link-example-storefront. Creates development symlinks for a single project.
make dev-unlink Removes docker-compose.override.yml symlinks from all projects.
make dev-unlink-<project-name> Example: make dev-unlink-example-storefront. Removes the docker-compose.override.yml symlink for a single project.
make rm Removes all containers. Volumes are not removed.
make rm-<project-name> Example: make rm-example-storefront. Removes all containers for a single project. Volumes are not removed.
make checkout-<project-name> <git-tag-or-branch-name> Example: make checkout-example-storefront release-v3.0.0. Does git checkout for a sub-project. See "Running Particular Git Branches" below.
make clean Removes all containers, networks, and volumes. Any volume data will be lost.
make clean-<project-name> Example: make clean-example-storefront. Removes all containers, networks, and volumes for a single project. Any volume data will be lost.
make update-checkouts Example: make update-checkouts. Updates git checkouts on all projects. Useful for syncing dev env to config file. Safe, fails on uncommitted changes.
make update-checkout-<project-name> Example: make update-checkout-example-storefront. Checks out branch in config file and pulls. Useful for syncing dev env to config file. Safe, fails on uncommitted changes.
make clone-api-plugins If you are going to make changes to the default plugins, this is a quick way to clone them all into an api-plugins subdirectory of this project.

Customizing Configuration

The development platform runs the latest version of Reaction by default, but it's possible to select a specific version, or to customize an existing release version.

How Configuration Works

The Reaction development platform uses make to run tasks. make is aware of the task dependency tree and ensures that all required dependencies are met when running a task. The main tasks and functionality for make are configured in Makefile.

Configurations that may change are extracted into config.mk. This file is checked in to source control and should not be modified. It is always configured for the latest Reaction release.

If a file named config.local.mk exists then it will be loaded after config.mk. Settings in config.local.mk will override those set in config.mk. It is ignored by source control.

Running a Specific Reaction Release Version

Configurations for specific Reaction releases (since v3.0.0) are located in config/reaction-oss. You may symlink or copy any release configuration to config.local.mk.

For example, this command will configure the platform to run v3.0.4:

ln -s config/reaction-oss/reaction-v3.0.4.mk config.local.mk
make

Running A Customized Installation

You may customize your Reaction installation by modifying config.local.mk. It's easiest to start with an existing release configuration file and modify it as needed. In this way you can:

  • Add new sub-projects
  • Remove sub-projects
  • Update the git origin for a sub-project
  • Change the default branch for a sub-project
  • Customize the lifecycle hooks directory to run custom scripts for automation

Configuration files store in config/local are ignored by git. It's a convenient place to store local files for quick development. If you are sharing files with a team then you may want to keep your configuration files in a separate git repository or in shared network storage.

The only requirement to override configuration is that you need to put a file into place at config.local.mk, so it is possible to copy or symlink a file from anywhere in your system.

Examples:

# Use a file in the config/local directory
ln -s config/local/my-custom-config.mk config.local.mk
make
# Use a file in the config/local directory
ln -s /path/on/my/system/reactionconfig.mk config.local.mk
make

Updating Local Branches to Match Config

If you are using the Reaction development platform for development, then you will need to update your local branch to get the latest at some point. The update-checkouts command will perform this operation.

make update-checkouts

The command is safe. It will halt if there are uncommitted changes in git before doing anything. You may commit, stash or drop those changes.

Running Particular Git Branches

After you've done the "Getting Started" steps and have the latest Reaction system running, you may need to switch to and run a certain branch/tag in one or more of the sub-projects.

To check out and run a certain branch or tag for a project, stop the project, run make checkout-<project-name> <git-tag-or-branch-name>, and then init the project again.

Example:

make stop-example-storefront
make checkout-example-storefront release-v3.0.0
make init-example-storefront

If you're getting unexpected results, cd into the sub-project directory and do a git pull to verify you're on the latest commit from that branch. If you're changing code files, see the "Running From Code For Development" section below.

Running From Code For Development

To ensure they start quickly, all Reaction projects are configured (in their docker-compose.yml file) to run from the latest published Docker image. This means that if you change code files, you will not see your changes reflected in the running application.

To install the whole platform in development mode:

Run make init-dev (instead of make).

Doing this takes time to install and will consume more resources.

To switch over to development mode for a single project:
make stop-<project-name>
make dev-link-<project-name>
make <start-project-name>

If you run into trouble with the above command, run make clean-<project-name> and then make init-dev-<project-name>.

To switch back to production mode for a single project:
make stop-<project-name>
make dev-unlink-<project-name>
make <start-project-name>

If you run into trouble with the above command, run make clean-<project-name> and then make init-<project-name>.

Networked Services

User-defined Docker networks are used to connect the Reaction services that run as separate Docker Compose projects. With this configuration, each of the projects can be launched independently using Docker Compose.

While the projects can be launched independently they may have network dependencies that are required to function correctly. The platform Makefile will launch services for you if you start it all together. You are free to manually start a single service but you will need to ensure dependencies are running.

Network Naming Strategy

All projects must list reaction.localhost as an external network in their docker-compose configuration. The make commands will ensure that this network exists. Choose a unique enough name for your service that you can be reasonably sure it won't conflict with another Reaction service.

When you need to communicate with one service from another over the internal Docker network, use <service-name>.reaction.localhost as the hostname.

Documentation

You may refer to each sub-project's README for additional operation details.

Sub-project Description Documentation
reaction GraphQL API Reaction API Documentation
reaction-admin Classic Admin UI Reaction Admin Readme
example-storefront Example Storefront Example Storefront docs

For tips on developing with Docker, read our Docker docs.

Latest Releases

The following table provides the most current version of each project used by this platform:

Project Latest release / tag
reaction-development-platform 4.0.1
reaction 4.0.0
example-storefront 5.0.3
reaction-admin (beta) 4.0.0-beta.5

Release Process

Developer Certificate of Origin

We use the Developer Certificate of Origin (DCO) in lieu of a Contributor License Agreement for all contributions to Reaction Commerce open source projects. We request that contributors agree to the terms of the DCO and indicate that agreement by signing-off all commits made to Reaction Commerce projects by adding a line with your name and email address to every Git commit message contributed:

Signed-off-by: Jane Doe <[email protected]>

You can sign-off your commit automatically with Git by using git commit -s if you have your user.name and user.email set as part of your Git configuration.

We ask that you use your real full name (please no anonymous contributions or pseudonyms) and a real email address. By signing-off your commit you are certifying that you have the right to submit it under the GNU GPLv3 Licensed.

We use the Probot DCO GitHub app to check for DCO sign-offs of every commit.

If you forget to sign-off your commits, the DCO bot will remind you and give you detailed instructions for how to amend your commits to add a signature.

License

Copyright © GNU General Public License v3.0

More Repositories

1

reaction

Mailchimp Open Commerce is an API-first, headless commerce platform built using Node.js, React, GraphQL. Deployed via Docker and Kubernetes.
JavaScript
12,320
star
2

example-storefront

Example Storefront is Reaction Commerce’s headless ecommerce storefront - Next.js, GraphQL, React. Built using Apollo Client and the commerce-focused React UI components provided in the Storefront Component Library (reactioncommerce/reaction-component-library). It connects with Reaction backend with the GraphQL API.
JavaScript
606
star
3

meteor-security

A Meteor package: Logical MongoDB security
JavaScript
258
star
4

reaction-component-library

Example Storefront Component Library: A set of React components for the Example Storefront
JavaScript
97
star
5

reaction-admin

Reaction Admin
JavaScript
88
star
6

reaction-docs

Documentation for Reaction, Reaction Platform, Example Storefront, and other supporting services.
CSS
68
star
7

mongo-rep-set

A Dockerized MongoDB for creating a three node replica set across separate hosts.
Shell
56
star
8

meteor-google-spreadsheets

Google Spreadsheets for Meteor
JavaScript
53
star
9

reaction-swag-shop

JavaScript
38
star
10

proxy-traefik

A reverse proxy powered by Traefik for deploying the Reaction Platform on Digital Ocean
35
star
11

reaction-cli

A command line tool for working with Reaction Commerce.
JavaScript
33
star
12

meteor-ddp-login

Meteor DDP login package
JavaScript
27
star
13

reaction-example-plugin

Example files to accompany the "Creating a Plugin" tutorial in the Customization Guide
JavaScript
22
star
14

reaction-devtools

Developer tools for Reaction
JavaScript
21
star
15

reaction-api-base

ARCHIVED: Demo GraphQL API server.
JavaScript
21
star
16

redoc

redoc - generate documentation from multiple project repos.
CSS
20
star
17

reaction-file-collections

Reaction File Collection packages
JavaScript
19
star
18

base

A base Docker image for Reaction Commerce (https://hub.docker.com/r/reactioncommerce/base)
Dockerfile
19
star
19

reaction-example-theme

Reaction Commerce example theme package
JavaScript
15
star
20

reaction-hydra

OAuth2 token server. Integrated with the Reaction development platform.
Shell
14
star
21

reaction-feature-requests

Reaction Feature Requests
14
star
22

spiderable

Docker + Ports friendly Meteor Spiderable
JavaScript
14
star
23

data-factory

Mock data factory util for Reaction Commerce
JavaScript
13
star
24

api-core

This NPM package provides the `ReactionAPICore` class. Use this to build a NodeJS microservice that is compatible with the Reaction Commerce platform, or to build your main Reaction Commerce API if you don't want to start by forking the https://github.com/reactioncommerce/reaction project.
JavaScript
10
star
25

components-context

A system for injecting React components into other React components from a central components context
JavaScript
9
star
26

reaction-styleguide

A plugin for Reaction, transforming it into a style guide and UI component playground.
JavaScript
9
star
27

random

A drop-in replacement for the "random" Meteor package
JavaScript
8
star
28

reaction-main-street-theme

A theme for Reaction Commerce based on bootstrap 4
CSS
8
star
29

catalyst

Catalyst Design System: A design system built by Reaction Commerce for Reaction Admin.
JavaScript
8
star
30

ci-scripts

Scripts supporting our Continuous Integration (CI)
Shell
8
star
31

reaction-identity

JavaScript
8
star
32

kinetic

Kinetic introduces a suite of opinionated admin tools that internal teams can use to manage and run their stores on Open Commerce.
TypeScript
7
star
33

reaction-sample-data

A collection of different datasets for testing and evaluating
7
star
34

pricewatch

Watch prices for change notifications.
Clojure
6
star
35

api-utils

Utility functions for the Reaction API.
JavaScript
6
star
36

federated-gateway

An access aware federated GraphQL API gateway for the Reaction Commerce ecosystem
JavaScript
6
star
37

cli

A command line tool for creating, developing and deploying Open Commerce projects
JavaScript
5
star
38

generator-reaction

Project generator for Reaction NodeJS projects. Built with Yeoman.
JavaScript
5
star
39

reaction-eslint-config

Reaction Eslint Configuration
JavaScript
5
star
40

mongo-s3-backup

A Docker container to backup a MongoDB deployment to S3 and list or restore those backups.
Shell
5
star
41

schemas

The collection schemas API for Reaction Commerce
JavaScript
4
star
42

migrator

Command line interface for migrating MongoDB databases
JavaScript
4
star
43

api-plugin-pricing-simple

Simple Pricing plugin for the Reaction API
JavaScript
4
star
44

reaction-health-check

A package to create a health-check route
JavaScript
4
star
45

api-plugin-example

Boilerplate Example Plugin for moving internal plugins to their own NPM packages for the Reaction API
JavaScript
4
star
46

api-migrations

This project tracks current desired versions for all tracks used by the default Reaction Platform.
JavaScript
4
star
47

docs

4
star
48

nodemailer

Send e-mails with Node.JS
JavaScript
4
star
49

docker-base

Dockerfile
4
star
50

admin-core

JavaScript
4
star
51

micro-frontend-admin

JavaScript
3
star
52

design

Board for design issues
3
star
53

reaction-job-queue

Reaction job queue collection
JavaScript
3
star
54

api-plugin-shops

Shops plugin for the Reaction API
JavaScript
3
star
55

api-plugin-products

Products plugin for the Reaction API
JavaScript
3
star
56

api-plugin-inventory

Inventory service for the Reaction API
JavaScript
3
star
57

mailchimp-open-commerce-helm-chart

Helm chart for deploying Mailchimp Open Commerce ontop of Kubernetes/Openshift.
Mustache
3
star
58

reekwire

Workaround for using CommonJS named exports in ES modules.
JavaScript
3
star
59

api-plugin-payments-stripe

Stripe Payments plugin for the Reaction API
JavaScript
3
star
60

hydra-token

Command line interface that makes it quick and easy to get a valid access token for a Reaction GraphQL API
JavaScript
3
star
61

api-plugin-payments-example

Example Payments plugin for the Reaction API
JavaScript
2
star
62

api-plugin-i18n

i18n plugin for the Reaction API
JavaScript
2
star
63

api-plugin-authentication

Authentication plugin for the Reaction API
JavaScript
2
star
64

api-plugin-files

Files plugin for the Reaction API
JavaScript
2
star
65

api-plugin-taxes

Taxes plugin for the Reaction API
JavaScript
2
star
66

api-plugin-sitemap-generator

Sitemap Generator plugin for the Reaction API
JavaScript
2
star
67

api-plugin-email-smtp

Email SMTP plugin for the Reaction API
JavaScript
2
star
68

logger

Reaction Commerce application logging API.
JavaScript
2
star
69

api-plugin-email-templates

Email Templates plugin for the Reaction API
JavaScript
2
star
70

api-plugin-email

Email plugin for the Reaction API
JavaScript
2
star
71

admin

TypeScript
2
star
72

hooks

The event hooks API for Reaction Commerce
JavaScript
2
star
73

api-plugin-accounts

Accounts plugin for the Reaction API
JavaScript
2
star
74

api-plugin-job-queue

Job Queue plugin for the Reaction API
JavaScript
2
star
75

reaction-error

Reaction error messaging
JavaScript
2
star
76

api-plugin-payments-stripe-sca

Stripe payments using the Payments Intents API
JavaScript
2
star
77

reaction-questions

Ask us questions about Reaction
1
star
78

api-plugin-navigation

Navigation plugin for the Reaction API
JavaScript
1
star
79

kube-helm

A lightweight Docker image with various CLI tooling for working with Kubernetes.
Shell
1
star
80

api-plugin-payments

Payments plugin for the Reaction API
JavaScript
1
star
81

api-plugin-shipments-flat-rate

Shipping Rates plugin for the Reaction API
JavaScript
1
star
82

babel-remove-es-create-require

JavaScript
1
star
83

admin-plugin-products

JavaScript
1
star
84

example-payments-plugin

An example payments plugin for Reaction Commerce
JavaScript
1
star
85

api-plugin-translations

Translations plugin for the Reaction API
JavaScript
1
star
86

api-plugin-address-validation-test

Address Validation Test plugin for the Reaction API
JavaScript
1
star
87

api-plugin-surcharges

Surcharges plugin for the Reaction API
JavaScript
1
star
88

api-plugin-orders

Orders plugin for the Reaction API
JavaScript
1
star
89

api-plugin-authorization-simple

Simple Authorization plugin for the Reaction API
JavaScript
1
star
90

api-plugin-carts

Carts plugin for the Reaction API
JavaScript
1
star
91

db-version-check

Data version checker function compatible with @reactioncommerce/migrator
JavaScript
1
star
92

api-plugin-discounts-codes

Discount Codes plugin for the Reaction API
JavaScript
1
star
93

admin-plugin-example

Example Reaction Admin plugin
JavaScript
1
star
94

api-plugin-address-validation

Address Validation plugin for the Reaction API
JavaScript
1
star
95

api-plugin-taxes-flat-rate

Tax Rates plugin for the Reaction API
JavaScript
1
star
96

api-plugin-discounts

Discounts plugin for the Reaction API
JavaScript
1
star
97

api-plugin-settings

Settings plugin for the Reaction API
JavaScript
1
star
98

api-plugin-simple-schema

Simple Schema plugin for the Reaction API
JavaScript
1
star
99

api-plugin-system-information

System Information plugin for the Reaction API
JavaScript
1
star
100

api-plugin-tags

Tags plugin for the Reaction API
JavaScript
1
star