Deployments - Ecotrust/hnfp GitHub Wiki

  1. Local

    • navigate to the parent directory of the application

      • i.e., parent dir of
        marineplanner-core /Users/you/project/hoonah/hnfp/
    • run:
      workbox injectManifest marineplanner-core/apps/hnfp/hnfp/workbox-config.js

      • workbox uses the settings in workbox-config.js to compile assests to be precached into the file sw.min.js
    • commit your changes and push
      git commit -m 'your message'
      git push origin

  2. Server

    • SSH into the server

    • cd app
      /usr/local/apps/marineplanner-core/

    • activate the env (do this now or after the next step)
      source /env/bin/activate

    • pull the lastest changes to the hoonah repo:
      cd apps/hnfp/
      git pull

    • navigate to marineplanner
      cd ../../marineplanner-core/marineplanner

    • then run the following:
      python manage.py collectstatic
      python manage.py compress
      sudo service uwsgi restart
      sudo service nginx restart

Postgres

[ToDo] su -u username psql -d database