sls-multi-universal
TypeScript icon, indicating that this package has built-in type declarations

1.3.1 • Public • Published

sls-multi-universal

NOTE: sls-multi-universal is based off of sls-multi-universal made by Edis Gonuler and modified by Youwei Zhen

sls-multi-universal is a tool that allows you to run multiple api gateways under one domain for local development purposes.

Here is a walkthrough article on medium

Installation

sls-multi-universal needs to be installed globally using the following command:

npm install -g sls-multi-universal

Usage

After installing sls-multi-universal, cd into your project directory

cd [project-directory]

Create a sls-multi-universal config file

touch sls-multi-universal.yml

Inside your sls-multi-universal config file add the services you would like to run

port: [port the proxy will run on - (optional: default is 3000)]
stage: [stage the proxy will run on - (optional: default is dev)]
services:
  - srvName: [name of the service]
    srvPath: [proxy path to the service]
    srvSource: [path to the serverless.yml file belong to that service]
    stripBasePath: [whether the srvPath will be passed on to the proxy]
  - srvName: [name of the service 2]
    srvPath: [proxy path to the service 2]
    srvSource: [path to the serverless.yml file belong to that service]
    stripBasePath: [whether the srvPath will be passed on to the proxy]

All srvPaths by default are mapped to localhost:[port]/[srvPath]. To remove srvPath , set stripBasePath to true.

To run sls-multi-universal, execute the following cmd in the directory with the config file

sls-multi-universal

Readme

Keywords

none

Package Sidebar

Install

npm i sls-multi-universal

Weekly Downloads

1

Version

1.3.1

License

ISC

Unpacked Size

7.57 kB

Total Files

9

Last publish

Collaborators

  • antodono