GithubHelp home page GithubHelp logo

hixi / osmaxx-frontend Goto Github PK

View Code? Open in Web Editor NEW

This project forked from geometalab/osmaxx

0.0 1.0 0.0 72.36 MB

Django-based web frontend for Osmaxx project

Home Page: http://osmaxx.hsr.ch/

License: MIT License

Makefile 0.46% Python 58.92% Shell 0.57% Groff 0.15% NSIS 0.67% PLpgSQL 0.79% Lua 0.68% JavaScript 31.68% CSS 2.67% HTML 3.39%

osmaxx-frontend's Introduction

Build Status (branch master)

Django-based Web Frontend for osmaxx.

For deploying a complete osmaxx setup, see https://github.com/geometalab/osmaxx

Development

Build Status (branch develop)

We do not recommend to run the application local on your machine but it's possible. We recommend to use the development docker containers.

Run it locally on Linux (Development)

Prerequisites

To run this project locally, you need sufficiently recent versions of docker and docker-compose installed.

Initialization

Development

Simply run

make local_dev_env

to set up *.env files suitable for local use of our docker-compose files. Do not use this for production! It will make use of insecure and hard coded passwords.

Production

Copy the environment folder compose-env-dist to compose-env and adapt the latter's content.

cp -r compose-env-dist compose-env
# Then, edit compose-env/*.env

Docker container bootstrapping

Development

For the rest of the readme, if in development:

  • set DEPLOY_VERSION to local (export DEPLOY_VERSION=local)
  • use docker-compose -f docker-compose.yml -f docker-compose-dev.yml

or source the helper script source activate_local_development. This enables to use docker-compose without all the -f options and without needing to specify DEPLOY_VERSION.

To setup all the containers and their dependencies by hand, run

docker-compose build

Production

In production, you should be setting DEPLOY_VERSION=xxx before running any of the commands below, where xxx is the version you'd like to deploy.

Generic

The rest of the documentation can be followed independently if on production or on development.

Update the containers

docker-compose pull

Then initiate the project defaults by running the following command:

docker-compose run frontend /bin/bash -c './manage.py createsuperuser'

Alternative to this command, bootstrap the container and execute the commands inside the container by hand:

docker-compose run frontend /bin/bash

Inside the container:

  1. (optional, recommended) setup a superuser: $ ./manage.py createsuperuser

Running the project

Start the containers using docker compose:

docker-compose up

Unsure which version is running?

Go to <your_ip>:8888/version/.

where <your_ip> is your public IP.

Testing

Can be found under Testing.

Documentation

See Wiki: https://github.com/geometalab/osmaxx/wiki

Problems & Solutions

ProgrammingError at /login/

relation "django_site" does not exist
LINE 1: ..."django_site"."domain", "django_site"."name" FROM "django_si...

You forgot to run the migrations

Tests failed, but worked before with no apparent change

Do not run docker-compose build --no-cache. Use docker-compose rm -f && docker-compose build, or if you really want to start clean, remove all docker containers

docker rm -f $(docker ps -q)

and remove all images

docker rmi -f $(docker images -q)

WARNING: This removes all containers/images on the machine and is discouraged in production.

osmaxx-frontend's People

Contributors

hixi avatar das-g avatar wasabideveloper avatar beneditatan avatar ltog avatar bhavyalight avatar eugenepjk avatar dhruv222 avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.