Fedora Metalink Proxy
A Flask-based web application that acts as a proxy for Fedora Metalink files, allowing filtering based on various criteria such as country, protocol, and preference.
Features
- Proxy for Fedora Metalink files with configurable filtering options
- Web interface for configuring filter settings
- Basic statistics and logging for monitoring request patterns
Prerequisites
- Docker
- Docker Compose
Setup
-
Clone the repository with:
git clone <repository-url>Then navigate to the project directory:cd <repository-directory> -
Configure environment variables by copying the example file:
cp .env.example .envThen edit the.envfile to set your desired configuration options. -
Build and run the Docker container with:
docker-compose up --buildThis command will build the Docker image and start the container.
Usage
Access the Application
Open a web browser and navigate to http://localhost:8182 to access the application.
Configure Filter Settings
Navigate to /dash/config to configure the filter settings for the Metalink proxy.
View Statistics
Navigate to /dash/stats to view basic statistics on request patterns.
Access Metalink Files
Use the /metalink endpoint with query parameters to fetch and filter Metalink files.
Example URL format:
http://localhost:8182/metalink?repo=fedora-42&arch=x86_64
Configuration
The application uses environment variables for configuration. Set these variables in the .env file:
EXCLUDED_COUNTRIES: List of country codes to excludePREFERRED_PROTOCOLS: List of preferred protocolsPREFERRED_TYPES: List of preferred typesMIN_PREFERENCE: Minimum preference value for filtering
License
MIT