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.

43 lines
1.1 KiB

  1. These install instructions assume a plain Ubuntu 16.04 server installation.
  2. ```sh
  3. sudo apt install apache2 libapache2-mod-php git php-cli composer nodejs-legacy npm php-curl
  4. sudo chmod 777 /var/www/html
  5. cd /var/www/html
  6. git clone https://github.com/plepe/openstreetbrowser.git
  7. cd openstreetbrowser
  8. npm install
  9. # At 'npm install' ignore the error "Failed at the openstreetbrowser lint
  10. # script 'standard src/*.js'. This just means that there are some errors with
  11. # the coding style, but this is not fatal.
  12. composer install
  13. git submodule init
  14. git submodule update
  15. cp conf.php-dist conf.php
  16. nano conf.php
  17. npm run build
  18. bin/download_dependencies
  19. ```
  20. For improved performance you should also run:
  21. ```sh
  22. modulekit/build_cache
  23. ```
  24. Browse to http://localhost/openstreetbrowser
  25. Have fun!
  26. # Debugging
  27. For debugging you should add the following line to conf.php:
  28. ```php
  29. $modulekit_nocache = true;
  30. ```
  31. Also you should run:
  32. ```sh
  33. npm run watch
  34. ```
  35. This is very similar to `npm run build`, but watches JavaScript files for
  36. changes and will update the dist/openstreetbrowser.js file. Also it will add
  37. debugging information to the final JavaScript file.