You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
rayburgemeestre 707db56ed1 Bump to docker 18.04 пре 5 година
.idea Add webassembly support. пре 6 година
dist Disable some possibly misleading benchmarks and transform one into an example. пре 6 година
docker_api Bump to docker 18.04 пре 5 година
docker_web Add Kubernetes config and some small fixes. пре 6 година
kube Add ingress and change path for data on my server пре 5 година
src Add example regarding sorting. пре 6 година
.gitignore Enable two replicas for the website to make it possible to do rolling upgrades. пре 6 година
.travis.yml Add travis CI and move files around, introduced Makefile пре 6 година
Makefile Small fixes пре 6 година
README.md Implemented storage few commits ago пре 6 година
package-lock.json npm audit fix again пре 5 година
package.json npm audit fix пре 5 година
webpack-dev.config.js Finally fix dev mode by setting contentBase. пре 6 година
webpack.config.js Finalize Dockerfile пре 6 година

README.md

Demo

https://cheerp.cppse.nl/

Project

The project constists of three parts:

  • The front-end (./src -> when compiled ./dist) UI based on VueJS.
  • The back-end API (./docker_api) uses a very simple Python Flask server, the back-end is deployed inside a docker container with the Cheerp compiler.
  • The docker image for the front-end (./docker_web) that only hosts the statically build files.

And all of the above is deployed on Kubernetes, for this see the ./kube directory.

Build

For nodejs projects it can be difficult to setup a dev environment. It’s probably important you use a new nodejs version, at least one compatible the one used: node-v10.12.0-linux-x64.

cd node-v10.12.0-linux-x64/bin
export PATH=$PATH:$PWD

Please verify that it’s working with:

trigen@zenbook:~/projects/cheerpweb[master]> node -v
v10.12.0
trigen@zenbook:~/projects/cheerpweb[master]> npm -v
6.4.1

Then use the Makefile when developing:

  • make dev - build and start a hot swapping debug server (very convenient while developing)
  • make api_dev - start the API server in a docker image running on port 5000.

Other useful directives:

  • make build - build the release version (in ./dist) of the UI (takes a while)
  • make docker_api - build the container that hosts the Cheerp compiler + Python Flask API server.
  • make docker_web - build the container that hosts the UI’s static files.
  • make prepare - wget the node version for this project, extract and install it to /usr/local.
  • make release - there are a bunch of other Makefile directives, but better just use this one to do everything required for a release.

Build status

Build Status MPL 2.0 License

Resources used for this project

Followed this readme for webpack: https://webpack.js.org/guides/getting-started/

Followed this for bulma: https://bulma.io/documentation/customize/with-webpack/

For vuejs: https://itnext.io/vuejs-and-webpack-4-from-scratch-part-1-94c9c28a534a

For devserver: https://itnext.io/vue-js-and-webpack-4-from-scratch-part-2-5038cc9deffb

Pass “reference” to child components https://stackoverflow.com/questions/40915436/vuejs-update-parent-data-from-child-component

License

MPL 2 , see LICENSE file.