An automated setup tool for configuring services and installing dependencies.
Project description
xcytos-setup Documentation
Overview
xcytos-setup is an automated setup tool designed to simplify the setup of Python environments. It verifies that necessary dependencies are installed, handles the configuration of ports and credentials, and offers an easy way to get your Python application up and running quickly.
File Structure
xcytos-setup/ # Root directory for xcytos setup
│
├── xcytxs_setup/ # Core setup logic inside this directory
│ └── __init__.py # Main Python module that holds the core logic
│
├── setup.py # The main setup script for the project
├── requirements.txt # List of required Python packages
├── LICENSE # Licensing information
├── README.md # Project documentation (this file)
Features
1. Python Verification
- Description: Ensures that Python is installed and available in the system.
- Functionality: Verifies Python’s presence by checking the Python version through system commands.
2. Install Requirements
- Description: Installs all Python dependencies specified in the
requirements.txt. - Functionality: If a
requirements.txtfile exists, the tool installs the dependencies usingpip install -r requirements.txt.
3. Dependency Discovery
- Description: Analyzes Python files in the project directory for any missing modules.
- Functionality: Looks for imported modules in the project’s
.pyfiles and checks if they are installed.
4. Port Handling
- Description: Prompts the user for available ports to use for the services.
- Functionality: Asks the user to enter port numbers for services like
mainandadmin. It ensures that the ports are not already in use on the system.
5. User Input (Username and Password)
- Description: Prompts for the username and password if they are not passed via command-line arguments.
- Functionality: Collects authentication information interactively or via arguments.
Command-Line Arguments
--port: Specifies the port to be used for services (e.g.,main,admin). The tool will ask the user interactively if not specified.--services: Defines the services (likemain,admin) that will be configured. Required when using--port.--username: Sets the username for application services.--password: Sets the password for application services.
Setup Instructions
1. Python Verification and Dependency Installation
To verify Python and install dependencies, run:
python xcytos-setup/setup.py --port 8000 --services main admin --username admin --password admin
2. Install Requirements
If the project includes a requirements.txt file, you can install the dependencies by running:
python xcytos-setup/setup.py
This will automatically install the required libraries if they are specified in the requirements.txt file.
How It Works
xcytos-setup Core Logic
- Python Verification: Ensures Python is installed by running
sys.executable --version. - Install Dependencies: Installs any missing dependencies from the
requirements.txtusingpip. - Dependency Discovery: Parses
.pyfiles to find any imported modules and confirms if they are installed. - Port Handling: Prompts users for port numbers to configure the
mainandadminservices. - Username & Password Configuration: Collects user credentials for services when not provided in the command-line arguments.
License
This project is licensed under the Apache License, Version 2.0. You can freely use, modify, and distribute the code under the terms specified in the license. A copy of the license is available in the LICENSE file in this repository.
Conclusion
xcytos-setup simplifies the process of setting up a Python project by automating dependency installations, verifying system configurations, and ensuring the environment is ready for running the application. It currently handles basic setup tasks and can be extended for more advanced configuration in future versions.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file xcytxs_setup-0.1.tar.gz.
File metadata
- Download URL: xcytxs_setup-0.1.tar.gz
- Upload date:
- Size: 16.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7de7b29640ce9a5ca9d6ee0ce7cdc2f0760707794edf6b9e224793be6b00d9c3
|
|
| MD5 |
7cbcf21d032ff005ad48a3bae6d83eba
|
|
| BLAKE2b-256 |
8e6462a082ed1fa544d111e8697797e422a37df59fd8672da512382de4b51280
|
File details
Details for the file xcytxs_setup-0.1-py3-none-any.whl.
File metadata
- Download URL: xcytxs_setup-0.1-py3-none-any.whl
- Upload date:
- Size: 17.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc3391bbc3c79f9230ef987fe0c5ae19dabc16a8d1c048cee740456ccf5179aa
|
|
| MD5 |
d9123d1e60e012d6d388816cc2dd9140
|
|
| BLAKE2b-256 |
f83b74554a16183a9f9628aa30d41da46f17e31e4fce3db52a4ac607689ddc57
|