Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Infra Requirements #8

Open
talkol opened this issue Jun 29, 2021 · 0 comments
Open

Infra Requirements #8

talkol opened this issue Jun 29, 2021 · 0 comments
Labels
help wanted Extra attention is needed

Comments

@talkol
Copy link
Member

talkol commented Jun 29, 2021

Deployment Through Git

  • Devs should git fork the template repo and push their master branch to deploy to production.
  • Devs should not be required to log into AWS console unless debugging edge issues.
  • Use Github Actions not circle CI.
  • Use serverless framework free / open source version.

Status: done (needs review)

Persistence

  • Let devs write to file system using EFS.
  • Working with EFS on AWS should not disrupt the function's outgoing connections to the Internet (known VPC issues).
  • Optional: arrange an easy way to browse EFS from the dev laptop or through AWS console.

Status: done (needs review, without the optional)

Typescript Support

  • Template repo code should be TypeScript (es6 imports and exports, no requires and no module.exports).
  • Change handler.js to handler.ts and put it in src directory.
  • Build should bundle into a single tree shaked JS file (with webpack).
  • Optional: move to ncc instead of configuring webpack manually.
  • Debugging: The ability to debug the type script file in webstorm & VScode

Status: done (needs review, without the optional)

Local Manual Testing

  • Let devs run their functions locally to play with it through npm script that takes function name as argument.
  • Rely on invoke local to implement the above since serverless already invested effort here.
  • Local run should use local file system, not EFS.

Status: not done

E2E Automated Test

  • Write an example simple E2E test in TypeScript that runs the function.
  • Connect the E2E suite to CI.

Status: not done

Logging

  • Let devs console.log from their function and have the log data available on CloudWatch.
  • Verify that stack traces on JS errors are meaningful, it's ok not to minify the source to achieve this.
  • Optional: use a tool to help devs give meaning to minified stack traces.
  • Optional: change the default CloudWatch log retention to 90 days.

Status: done (needs review, without the optional)

Custom Metrics

  • Choose time series DB to hold the custom metrics (probably InfluxDB - check with @uv-orbs).
  • Give devs a simple function to call in order to report the custom metrics through HTTP.
  • Configure grafana to display the custom metrics.

Status: not done

Security

  • Configure a simple method to send secrets to the function, can either use Github Repo Secret as environment variables or connect to AWS Secrets Manager.
  • Reduce permissions of the CI AWS user that deploys the functions to a minimum.

Status: not done

@talkol talkol added the help wanted Extra attention is needed label Jun 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Development

No branches or pull requests

1 participant