p5.js-web-editor/README.ruben.md
2020-12-17 10:58:41 +01:00

1.3 KiB

Usage

There is a hidden link to have an overview of all users registered on the server: /users.

Development

docker-compose -f docker-compose-development.yml up

Deployment

Manual

  • Push to git (in case linting fails on commit use git commit --no-verify)
  • Pull on server.
  • service p5.js-web-editor stop
  • npm run build:server
  • npm run build:client
  • service p5.js-web-editor start

Docker

Branch single_docker has a Frankenstein Dockerfile to embed mongo in the single image for deployment to Plex (which doesn't know docker-compose...)

To build an image called digitalplayground:

docker build -t digitalplayground .

To run it we provide the port to publish, and need to map the volumes of mongo for persistent storage (don't use the tmp folder from the example if you really want persistent storage):

docker run -it --env-file .env.production --publish 8001:8000 -v /tmp/dp/db:/data/db -v /tmp/dp/configdb:/data/configdb digitalplayground

s3 storage

Gebruik s3cmd om bucket in te stellen.

Make bucket:

s3cmd mb s3://digitalplayground-p5

Set the CORS rules

s3cmd -c .s3cfg setcors CORS.xml s3://digitalplayground-p5

Delete the CORS rules

s3cmd -c .s3cfg delcors s3://digitalplayground-p5

Get bucket info including CORS rules

s3cmd -c .s3cfg info s3://digitalplayground-p5