This project demonstrates the integration of FastAPI with Docker to manage Docker containers via a RESTful API. It provides endpoints to list containers, show container details and logs, kill containers, and start containers.
This project provides a graphical user interface (GUI) using Vue for administering Docker container management package. It enables managing Docker containers via a RESTful API.
Docker-FastAPI-Integration-with-Vue-GUI.
- Open Terminal.
- Check if Python 3 is already installed by running:
python3 --version - If Python 3 is not installed, download and install it from the official Python website: Python Downloads.
- Open Terminal.
- Use the package manager to install Python 3:
sudo apt update sudo apt install python3
- Download the Python 3 installer from the official Python website: Python Downloads.
- Run the installer and follow the installation instructions.
Pip is the package installer for Python. You can install it using the following steps:
- Download
get-pip.pyfrom https://bootstrap.pypa.io/get-pip.py. - Open Terminal (or Command Prompt on Windows).
- Navigate to the directory containing
get-pip.py. - Run the following command:
python get-pip.py
After installing Python and Pip, navigate to the project directory and run the following command to install the project dependencies:
pip install -r requirements.txt
This will install FastAPI and Docker packages necessary for the project.
To run the application, use the following command:
uvicorn main:app --reload --port 8000
This command starts the FastAPI server with auto-reload enabled, listening on port 8000. You can access the API at http://localhost:8000/docs.
for build to system
pyinstaller --onefile --exclude PyQt5 main.py