This repo is meant to help you navigate the Mutable app and managing your service stack. We provided a boilerplate project and a walkthrough for using the Mutable app
This stack uses our prepared boilerplate services available in Mutable's public repos.
Backend service: Repo
Frontend service: Repo
Proxy service: Repo
- Create a
mutable
folder where your mutable projects will be located. Only projects inside this folder will show up inside Mutable application. - Git clone this repository into the
mutable
folder you created. - In Mutable application settings, write the directory of your
mutable
folder, then hit the save button on the bottom. - In terminal, navigate inside the three folders
backend
,frontend
,proxy
andnpm install
them. - Execute
npm run build
insidefrontend
folder. - In terminal, open
/etc/hosts
file bysudo nano /etc/hosts
command and add the following row at the end:127.0.0.1 mutable.local
- Inside Mutable application, navigate into
boilerplate-node-react
stack, thenproxy
service, then toConfiguration
tab - Add the routing settings below and hit the Save button. This lets services know where to redirect different routes.
{
"hosts": {
"mutable.local": {
"routes": {
"api": {
"target": "http://backend/[~]"
}
},
"target": "http://frontend/[~]"
}
},
"page404": "<html><head><style>h1{margin: auto; position: absolute; top: 0; left: 0; right: 0; bottom: 0; height: 100px; font-family: ‘arial’; font-weight: 100; color: #555; text-align: center; }body{background:#eee;}</style></head><body><h1>404 Not Found</h1></body></html>",
"publish": [
"backend",
"frontend"
]
}
- Run
backend
,frontend
andproxy
services. Then open your browser and visitmutable.local:8888
And thats it. You can add more services and api endpoints, by creating them and then editing the Configuration settings of the Proxy service to match the api call with its intended target and then publishing it by adding to the "publish" field.