From 1d4b170ea17b26f9cb76ddae289ab9af747c52db Mon Sep 17 00:00:00 2001 From: Alexander Cerutti Date: Sat, 11 Dec 2021 16:27:32 +0100 Subject: [PATCH] Added additional explanation steps for examples --- examples/self-hosted/README.md | 11 +++++++++-- examples/serverless/README.md | 7 +++++++ 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/examples/self-hosted/README.md b/examples/self-hosted/README.md index 8001b4f..a8c343a 100644 --- a/examples/self-hosted/README.md +++ b/examples/self-hosted/README.md @@ -2,11 +2,18 @@ This is examples folder. These examples are used to test new features and as sample showcases. -Each example owns an endpoint where a pass can be reached. This project is build upon Express.js, which is required to be installed. +Each example owns an endpoint where a pass can be reached. This project is built upon Express.js. Typescript compilation is done automatically through `ts-node`. -Assuming you already have cloned this repository, installed its dependencies through `npm install` and moved to `examples/self-hosted`, run these commands: +Before generating a new pass, you'll have to override the `passTypeIdentifier` and `teamIdentifier` for them to match the data in your certificates. This can be done in two ways: + + a) Edit manually the `pass.json` of the model you are going to run; + b) Pass the two fields in the query string of the example you are running when querying it; + +Omitting this step, will make your pass unopenable. + +Assuming you already installed this project its dependencies through `npm install` and moved to `examples/self-hosted`, run these commands: ```sh $ npm install; diff --git a/examples/serverless/README.md b/examples/serverless/README.md index b150d0b..3e3ab97 100644 --- a/examples/serverless/README.md +++ b/examples/serverless/README.md @@ -4,6 +4,13 @@ This is a sample project for showing passkit-generator being used on cloud funct Typescript compilation happens automatically through `serverless-plugin-typescript` when serverless is started. +Before generating a new pass, you'll have to override the `passTypeIdentifier` and `teamIdentifier` for them to match the data in your certificates. This can be done in two ways: + + a) Edit manually the `pass.json` of the model you are going to run; + b) Pass the two fields in the query string of the example you are running when querying it; + +Omitting this step, will make your pass unopenable. + ## Configuration These examples are basically made for being executed locally. In the file `config.json`, some constants can be customized.