Skip to content
💼 Web application for recruitment platform
CSS HTML JavaScript Python
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app
data
messages
.codeclimaye.yml
.editorconfig
.gitignore
CONTRIBUTING.md
Dockerfile
LICENSE
Procfile
README.md
app.json
babel.cfg
docker-compose.yml
manage.py
requirements.txt
runserver.py
runtime.txt

README.md

forumorg

Website Maintainability Packagist

This is the repository of Forum Organisation's official website.

Requirements

To run this project, the only requirement you'll need is Docker.

To check if it's been installed correctly, running docker --version && docker-compose --version should output:

Docker version 19.xx ...
docker-compose version 1.17.xx ...

After checking out the project, you need to copy-paste .env.example to .env and fill it:

BUCKET_NAME=bucket_name # Required: S3 bucket name
SENDGRID_API_KEY=sendgrid_key # Optional: emailing API
RECAPTCHA_SECRET_KEY=recaptcha_key # Optional: captcha API

To start the application, run docker-compose up -d and your app should be deployed at http://localhost:8080

For debuggings reasons, you can access logs (or attach to bash) by running:

docker exec -ti $(docker ps | grep web | awk '{print $1}') sh
docker-compose logs -f web
# P.S: replace web by mongodb to access db container

You can also access a web-based MongoDB admin interface useful for viewing/modifying local db by going to http://localhost:8081

Localization

The app is localized using Flask-Babel. Strings which needs to be translated are surrounded with _('STRING').

Deployment process

The application is deployed on Heroku.

After installing Heroku CLI, you'll need to set Heroku to recognize your local directory as the heroku app:

git remote add production https://git.heroku.com/forumorg-prod.git
git remote add staging https://git.heroku.com/forumorg-staging.git

Github -> Heroku

On any pull request (see how):

  • A temporary review app is created, which can be live tested.
  • If everything is working OK, the PR can be merged into master.

On push to master:

  • A build is triggered on our staging app (useful for testing in a production-like environment).

On heroku pipelines:promote -r staging --to production:

  • The staging app is instantly deployed to production.

Running scripts

Some tasks (like mass updates on database) require execution of scripts on deployed apps.

You can execute a script by adding it to manage.py as a python function, then run:

heroku local:run python manage.py my_script

Contributions

Contributions are very welcome! If you find a bug or some improvements, feel free to raise an issue and send a PR. Please see the CONTRIBUTING file for more information on how to contribute.

Contributors

(Note to contributors: Add yourself in alphabetical order!)

License

This project is licensed under the MIT License - see the LICENSE file for details

You can’t perform that action at this time.