reactioncommerce / reaction-feature-requests

Reaction Feature Requests
13 stars 1 forks source link

make stripe optional #133

Closed mariusa closed 3 years ago

mariusa commented 3 years ago

Trying to run reaction locally, it doesn't start without a valid Stripe key.

Please make stripe optional, just disable payments with card if no stripe key. One could use only PayPal or Mollie.

mariusa commented 3 years ago
$ cat .env

MONGO_URL=mongodb://mongo.reaction.localhost:27017/reaction
ROOT_URL=http://localhost:3000
STRIPE_API_KEY=2lkjsaf
[marius@localhost work/reaction]$ npm run start:dev

> reaction-api@3.9.0 start:dev /home/marius/work/reaction
> npm run check-node-version && NODE_ENV=development NODE_OPTIONS='--experimental-modules --experimental-json-modules' nodemon ./src/index.js

> reaction-api@3.9.0 check-node-version /home/marius/work/reaction
> node ./src/checkNodeVersion.cjs

(node:1052457) ExperimentalWarning: The ESM module loader is experimental.
[nodemon] 1.19.4
[nodemon] to restart at any time, enter `rs`
[nodemon] watching dir(s): src/**/*
[nodemon] watching extensions: js,cjs,mjs,json,graphql
[nodemon] starting `node ./src/index.js`
(node:1052488) ExperimentalWarning: The ESM module loader is experimental.
(node:1052488) ExperimentalWarning: Importing JSON modules is an experimental feature. This feature could change at any time
================================
 Missing environment variables:
    STRIPE_API_KEY: A private Stripe API key

 Exiting with error code 1
================================
[nodemon] app crashed - waiting for file changes before starting...
brent-hoover commented 3 years ago

@mariusa I believe if you edit your plugins.json and remove the Stripe plugin, this will no longer happen. The included example-payment method should still work for simple testing purposes

mariusa commented 3 years ago

Thanks! That solved it