Giter Site home page Giter Site logo

victor-yunenko / eahub.org Goto Github PK

View Code? Open in Web Editor NEW

This project forked from david-mears/eahub.org

1.0 1.0 0.0 5.37 MB

Home Page: https://eahub.org

License: MIT License

Python 37.82% Dockerfile 0.18% HTML 38.13% JavaScript 14.23% CSS 5.55% Shell 0.22% TypeScript 0.21% Vue 0.02% SCSS 3.63%

eahub.org's Introduction

Backend for https://eahub.org

eahub.org reboot

Build Status

Setup

  1. Make sure to have Docker Compose installed. (Note: You may need to follow these post-installation steps.)

  2. Add the following line to your hosts file (/etc/hosts on Mac or Linux, %SystemRoot%\System32\drivers\etc\hosts on Windows):

    127.0.0.1 objstore
    
  3. docker-compose run web django-admin createcontainer
    
  4. docker-compose run web django-admin migrate
    

Running

$ docker-compose up

If everything went well, you should have a number of containers now being served (use docker ps to get a list of them). You should be able to get the Hub at http://localhost:8000.

If the Dockerfile has changed since last time you did this, you'll need to run docker-compose up --build or docker-compose build.

If the database schema has changed since last time, you'll need to run docker-compose run web django-admin migrate.

Rebuilding frontend in development

Requires: Node.js v10

To see live changes to the frontend while developing,

  • Run docker-compose up
  • Open a new terminal window and run npm install (if you run it for the first time)
  • Run npm run build-watch

Running Tests

$ docker-compose run --use-aliases web pytest

Running Frontend Test

Requires: Node.js
If you're running these for the first time or package.json has changed, run npm install Then run npm test

Formatting Code

$ docker-compose run web black .

You must run this before sending a pull request or else it will be automatically blocked from merging.

You can also automatically sort your imports:

$ docker-compose run web isort -rc --atomic .

Deploying

After uploading a new docker image, the website will automatically update

$ cd eahub
$ docker build -t eahub:latest .
$ docker system prune --force
$ docker tag eahub eahub.azurecr.io/eahub:latest
$ docker push eahub.azurecr.io/eahub:latest

Running django commands

$ docker-compose run web bash
$ docker-compose run web django-admin shell
$ docker-compose run web django-admin makemigrations
$ docker-compose run web django-admin migrate

Docker Image Registry Login

  • Images are privately saved to our Azure Container Registry
$ docker login eahub.azurecr.io
>>> username: eahub
>>> password: <see lastpass>

Browser Support Policy

We support the most recent version of Google Chrome, Mozilla Firefox, Safari, and Microsoft Edge.

We support browsers with JavaScript disabled, but they will receive a degraded experience without dynamic client-side functionality. Because our JavaScript works only in modern browsers, legacy browsers like Internet Explorer receive the same degraded experience.

Commit Message Practices

These are primarily for the benefit of maintainers, but all contributors are urged to follow them in order to make maintainers' lives easier.

  • In general, follow the practices outlined in "How to Write a Git Commit Message" by Chris Beams.
  • As an exception to the above, do not manually wrap the body of a commit message. The main reason for this is because our workflow depends on the GitHub web interface, which doesn't provide an easy way to do this. It does not depend on emailing patches, so the benefits of wrapped lines don't apply. There is arguably some benefit to the usability of git log, but it doesn't outweigh the costs.
  • Maintainers should use GitHub's squash merging exclusively. Merge commits and rebase merging have been disabled in GitHub.

eahub.org's People

Contributors

austin226 avatar berndverst avatar cafelow avatar cephalin avatar david-mears avatar dependabot[bot] avatar lisajd avatar manoj-nathwani avatar marcin-wosinek avatar michaltrzesimiech avatar microsoftopensource avatar msftgits avatar patbl avatar richenda avatar taymonbeal avatar

Stargazers

 avatar

Watchers

 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.