Giter Site home page Giter Site logo

articles-api's Introduction

Articles navigator

A dockerized FastAPI App with 2 options of rendering (server-side and React frontend). Provides the opportunity for users' articles navigation with standard user authentication system. App structure


PostgreSQL is used for collecting data about users and their articles, MongoDB is used for registrating events. The rendering server has some additional functionality compared with the React frontend: it is connected with RabbitMQ and Sentry. RabbitMQ is used while the rendering server pushes message about a new registered user into a queue and the listening server listens to this queue. Sentry is used for registrating server errors.


CodeClimate and CI status

Python CI

Links

This project was built using these tools:

Tool Description
FastAPI "Web framework for building APIs with Python"
PostgreSQL "An open source object-relational database system"
SQLAlchemy "The Python SQL toolkit and Object Relational Mapper"
Alembic "A lightweight database migration tool for usage with the SQLAlchemy"
MongoDB "A NoSQL database program"
React "A JavaScript library for building user interfaces"
RabbitMQ "An open source message broker"
poetry "Python dependency management and packaging made easy"
Py.Test "A mature full-featured Python testing tool"
Sentry "Application Monitoring and Error Tracking Software"

Installation

Copy a project

$ git clone [email protected]:Dddarknight/articles-api.git
$ cd articles-api 

Set up environment variables

$ touch .env

# You have to fill .env file. See .env.example.
# You will have to fill username and password fields for PostgreSQL, RabbitMQ, email (from this email messages will be sent to moderators). If you don't have these credentials, please follow the instructions in the official documentation.

# To get a SECRET_KEY for FastAPI run:
$ openssl rand -hex 32

Set up environment variables for frontend

$ cd frontend
$ touch .env
# Then you have to fill .env file in frontend for Firebase project configuration. See .env.example.

Working with Docker

$ cd ..

# If you haven't used Docker earlier, you should follow the installation instruction on the official website (https://docs.docker.com/engine/install/).
# Then:
$ sudo apt install docker-compose

$ docker-compose up -d --build

Description and usage

Functionality connected with users management

Page Description
Sign-up First you need to register in the app using the provided form of registration.
Log in Then you have to log in using the information you've filled in the registration form. JSON Web Tokens are used for authorization.
Users You can see list of all users on the relevant page.
User The information about the user. The user's data can be changed or deleted only by the authorized user.

Functionality connected with articles management

Page Description
Articles Here you can see the list of users' articles. Also here you can create a new article.
Article Only authorized user's article can be changed or deleted.

License

GNU GPLv3

articles-api's People

Contributors

dddarknight avatar

Stargazers

Dmitriy Filyushin avatar Vladimir Tikhonov 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.