Problem to solve
Allow the user to choose a built-in template when creating a new project that provides them with the basic project structure and configuration to have their frontend deployed to GitLab Pages and their serverless functions to AWS Lambda.
The example project will consist of:
- single project repo for frontend and backend code
gitlab-ci.ymlfile with configuration to:
- run tests
- run build steps
- deploy frontend code to GitLab Pages
- deploy serverless functions to AWS Lambda
README.mdfile with the documentation for:
- how to get and set up AWS credential variables
- how to serve the API endpoints over a custom domain (to avoid CORS issues). e.g.
- expected function signatures
- link to the serverless documentation about extending this setup
- all the variable parts (like AWS credentials, but even the backend and frontend project paths) are to be set as environment variables in
- the AWS region will be defined in
- Test that checks for AWS keys are installed correctly
Language-specific details for example project
- The frontend will be a simple static page with a button that when clicked makes a call to the serverless function and prints out the response
- The serverless function will return a JSON object consisting our of any request parameters passed with the request
- The project will be set to be compatible with NodeJS v10
Won't do now
- we won't provision a
serverless.yamlfile automatically based on some existing exported set of functions. We might do it in the future though. We create a
serverless.yamlwhen we create the project, and the user should extend it as they want.
What does success look like, and how can we measure that?
- A user can create a new project from the template, set their configuration variables, run the pipeline and see the frontend and backend deployed and the frontend successfully makes a call to the serverless function and receive a valid response.
- Add tracking data to Snowplow whenever a project is created from this template.
- We should create a blog post and post it to various newsletters to see how it resonates with the developer community.