https://github.com/s0fft/true-publish-protocol
Information-Resource — SSR Media Project on Flask + API on Flask-RESTful
https://github.com/s0fft/true-publish-protocol
api curl flask flask-restful jinja2 postman python3 server-side-rendering sqlalchemy sqlite
Last synced: 3 months ago
JSON representation
Information-Resource — SSR Media Project on Flask + API on Flask-RESTful
- Host: GitHub
- URL: https://github.com/s0fft/true-publish-protocol
- Owner: S0fft
- License: mit
- Created: 2024-09-18T15:26:25.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-31T14:54:58.000Z (over 1 year ago)
- Last Synced: 2025-06-17T17:51:00.504Z (9 months ago)
- Topics: api, curl, flask, flask-restful, jinja2, postman, python3, server-side-rendering, sqlalchemy, sqlite
- Language: Python
- Homepage:
- Size: 288 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# True-Publish-Protocol
#### Information-Resource — SSR Media Project on Flask + API on Flask-RESTful
An information platform that allows users to publish a variety of articles.
The application is built using SSR architecture and also includes an API for managing articles.
#### Stack:
- Pyhton
- Flask
- Flask-RESTful
- Jinja2
- SQLAlchemy
- SQLite
Additional libraries are specified in the `requirements.txt` file.
## Project Setup on Windows
### - Installing the Stack
To begin, install: [Python](https://www.python.org/downloads/)
Links are provided to the latest version of the tools.
### - Cloning a Project from GitHub
Create a root directory on your computer, then open it in your code editor or terminal.
Next, write this command into the command line:
```powershell
git clone https://github.com/S0fft/True-Publish-Protocol.git
```
You will see the project files appear in your directory.
### - Creating a Virtual Environment
Create a virtual environment:
```powershell
python -m venv .venv
```
And activate it:
```powershell
.venv\Scripts\Activate
```
### - Installing the Requirements
Next, install packages:
```powershell
python.exe -m pip install --upgrade pip
```
```powershell
pip install -r requirements.txt
```
### - Applying the Migrations
Run the console in the root directory of the project to access application files and the database.
```bash
python
```
Afterwards, apply migrations in the Python console
```bash
app.app_context().push()
db.create_all()
```
### - Running the Server
Then, run server:
```powershell
python main.py
```
After starting the server, you can access the application by navigating to `http://127.0.0.1:5000` in your browser.
Project Setup on Unix-Like Systems
These commands do the same thing as described above:
### - Installing the Stack
To begin, install: [Python](https://www.python.org/downloads/)
Links are provided to the latest version of the tools.
### - Cloning a Project from GitHub
Create a root directory on your computer, then open it in your code editor or terminal.
Next, write this command into the command line:
```powershell
git clone https://github.com/S0fft/True-Publish-Protocol.git
```
You will see the project files appear in your directory.
### - Creating a Virtual Environment
```bash
python3 -m pip install --upgrade pip
```
```bash
source ./venv/bin/activate
```
### - Installing the Requirements
```bash
pip install --upgrade pip
```
```bash
pip install -r requirements.txt
```
### - Applying the Migrations
Run the console in the root directory of the project to access application files and the database.
```bash
python3
```
Afterwards, apply migrations in the Python console
```bash
app.app_context().push()
db.create_all()
```
### - Running the Server
```powershell
python main.py
```
After starting the server, you can access the application by navigating to `http://127.0.0.1:5000` in your browser.