I wanted to be able to install Webiny as a locally hosted CMS, without dependencies on Amazon services. This is not something Webiny supports out of the box (and afaik it’s not a goal of the developers), so I modified the default template to work locally.
Here is the result: https://gitlab.com/shrugal/webiny-local
The changes are basically:
- Replace MongoDB lambda plugin with the local variant
- Replace Cognito security plugins to just use the username and password stored in MongoDB
- Replace Serverless Components with copies that don’t include any Lambda or S3 interactions
- Replace Lambdas with simple ExpressJS servers (one for each service: api, admin and site)
- Add the file server from an older Webiny CLI back to the api service
- Skip installing example data for page-builder (would require S3)
- Clone repo
apps/site/.env.jsonfrom their respective example files and fill in
JWT_SECRETin the api config.
yarn run build:dev:api(has to run whenever you change
yarn run start
- Complete installation and hack away!
Build and run:
yarn run build
yarn run serve
Hope this might help someone,