ps-serverless-app icon indicating copy to clipboard operation
ps-serverless-app copied to clipboard

Some issues encountered: Tools and runtime error

Open mike-whittaker-work opened this issue 1 year ago • 0 comments

npm -v: 9.5.1 npx -v: 9.5.1 yarn -v: 1.22.19 and eventually, cdk --version: 2.79.1 (build 2e7f8b7)

I am guessing that these are down to the vagaries of Node dependencies, not any shortcoming in the demo code itself :-D

  1. To install CDK, requires sudo npm install -g aws-cdk - not the command shown in the course (which fails). And just npx cdk bootstrap aws://<account>/<region>
  2. The first run of yarn brings up a list of warnings, which are not present on a second run. Maybe the "fixes" contribute to 3 ?
  3. To successfully run the web app (yarn start) from p1 to p2, requires: export NODE_OPTIONS=--openssl-legacy-provider due to error:03000086:digital envelope routines
  4. From p3 onwards, run-time error on yarn start(TypeError: Cannot read properties of undefined (reading 'apiEndpoint')) caused by webapp/src/services/index.js: const SERVICES_HOST = window.appConfig.apiEndpoint OK: Got it - the appconfig tools require the value from a deployment bucket, which is not present in a "yarn start" environment. Hence it maybe could detect it's running in that environment.

mike-whittaker-work avatar May 19 '23 09:05 mike-whittaker-work