This README outlines the details of collaborating on this Ember application. A short introduction of this app could easily go here.
Getting working dev environment used to be problematic, because parts of the web still rely on deprecated libraries. For that reason,
docker-compose file were created to make it incredibly easier. Now, all you have to do is have docker setup (which is really easy) and run:
git clone https://github.com/fi-ksi/web-frontend.git cd web-frontend git submodule init git submodule update
To build and start server run the following line. The first run will take ~10 minutes to install everything thats needed, each following build should take about ~15 seconds.
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker-compose up -d --build ember_server # DOCKER_BUILDKIT is used for building to dist folder. If you also use it for server container, it will use the existing cache. # If you don't care about cache, the following should work just fine: # docker-compose up -d --build
To build the version for test server and place it in
dist folder run the following line. If you want to build for production server, use
production instead of
rm -r dist/ || DOCKER_BUILDKIT=1 ENVIRONMENT_SELECTOR=remote_dev docker build --target build_dist_stage -o dist --build-arg environment_selector=$environment_selector .
Docker on Windows - no auto rebuild
Just one small problem - on Docker for Windows notifications on shared drives/volumes are not fully implemented. That means watchman won't automatically rebuild. After every change you need to manually run the
docker-compose up -d --build (or alternative) and do rebuild of the ember website. All docker things are cached, so only the website itself will rebuild.
You will need the following things properly installed on your computer. You also need compatible versions not only between those prerequisites, but also with libraries. We strongly recomend using the docker version, or at least looking to it's files to see which versions are used.
git clone <repository-url>this repository
- change into the new directory
git submodule init
git submodule update
Running / Development
- Visit your app at http://localhost:4200.
- If you want to be able to access content from backend on test server (kyzikos) you either need to be in MU network or on the MU VPN. Also, kyzikos has CORS, so make sure that you access your local frontend on
localhost:4200, not on
Make use of the many generators for code, try
ember help generate for more details
ember test --server
ember build --environment=production(production for ksi.fi.muni.cz)
ember build --environment=remote_dev(development for kyzikos.fi.muni.cz)
./deploy-ksi.shto deploy at ksi.fi.muni.cz.
./deploy-dev.shto deploy at kyzikos.fi.muni.cz.
- We do not use tabs.
- Tab = 4 spaces.