-
Notifications
You must be signed in to change notification settings - Fork 32
Setup and Running
Follow these instructions to get the PCLink server running on your local machine from the source code.
- Python 3.12+: Ensure you have a modern version of Python installed.
- Pip: Python's package installer.
-
Clone the Repository: If you have the project source, navigate to the root directory.
-
Install Dependencies: PCLink uses a modern Python packaging system. The recommended way to install all dependencies for development is:
# Install the package in development mode with dev dependencies pip install -e ".[dev]"
Key dependencies include:
-
fastapi- Web framework -
uvicorn[standard]- ASGI server -
websockets- WebSocket support -
psutil- System information -
pynput- Input control -
cryptography- SSL/TLS support -
pystray- System tray integration -
jinja2- Templating engine for the Web UI
Note: Some dependencies like
pywin32are Windows-specific. On Linux,PyGObjectis required for native tray support. -
Before installing Python dependencies, you may need these system packages to enable all features (including native notifications and desktop streaming):
Ubuntu/Debian:
sudo apt update
sudo apt install python3-gi gir1.2-appindicator3-0.1 libayatana-appindicator3-0.1 wl-clipboard gnome-screenshot libgstreamer1.0-0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-uglyFedora/RHEL:
sudo dnf install python3-gobject libayatana-appindicator-gtk3 wl-clipboard gnome-screenshot gstreamer1-plugins-base gstreamer1-plugins-good gstreamer1-plugins-bad-free gstreamer1-plugins-ugly-freeThe server is designed to be run as a Python module from the root of the project directory.
-
Navigate to the project's root directory (the one containing the
srcfolder). -
Run the application using the following command:
python -m pclink
If you have installed the package as a system-wide tool or in a virtual environment, you can simply run:
pclink
Upon first launch, the server will perform pre-flight checks, generate a self-signed SSL certificate, and create necessary configuration files in your user's application data directory.
The server will start, and you can access the Web UI by navigating to https://localhost:38080 in your web browser.
The server accepts a few command-line arguments to change its behavior:
-
--startup: Runs the application in headless/background mode. This is used when the application is configured to start automatically with the operating system. -
--helpor-h: Displays a help message with usage instructions.
The launcher.py script is intended for use in packaged, standalone executables (e.g., created with PyInstaller) and is not typically run directly during development. It handles special setup tasks for distributed applications, such as setting up Windows Firewall rules and DPI awareness.