Skip to Content
Installation

Installation

Get Asantiya up and running on your system with this comprehensive installation guide.

Prerequisites

Before installing Asantiya, ensure you have the following components installed and configured:

1. Python & Pip

Asantiya is a Python-based tool, so you’ll need:

  • Python 3.9 or higher installed on your system
  • pip (Python package installer) available on your system PATH

Check your Python version:

python --version # or python3 --version

Check pip availability:

pip --version # or pip3 --version

Install Python (if needed):

  • Windows: Download from python.org
  • macOS: Use Homebrew - brew install python
  • Linux: Use your package manager (e.g., sudo apt install python3 python3-pip)

2. Docker

Asantiya relies on Docker to build and deploy applications, both locally and remotely. Docker must be installed and running before using Asantiya.

For Windows/macOS:

Install Docker Desktop - the easiest way to get Docker running:

For Linux:

Choose between Docker Desktop or Docker Engine:

Verify Docker installation:

docker --version docker run hello-world

Installation Methods

The easiest way to install Asantiya is using pip:

pip install asantiya

For Python 3 specifically:

pip3 install asantiya

Install specific version:

pip install asantiya==0.1.3

Method 2: From Source

If you want to install the latest development version:

# Clone the repository git clone https://github.com/shahid-0/asantiya.git cd asantiya # Install in development mode pip install -e . # Or install with development dependencies pip install -e ".[dev]"

For isolated installations:

# Create virtual environment python -m venv asantiya-env # Activate virtual environment # On Windows: asantiya-env\Scripts\activate # On macOS/Linux: source asantiya-env/bin/activate # Install Asantiya pip install asantiya

Verify Installation

After installation, verify that Asantiya is working correctly:

Check version:

asantiya --version # Expected output: asantiya v0.1.3

Check help:

asantiya --help # Should display available commands and options

Test Docker integration:

# Check Docker status docker --version docker info # Test Docker connectivity docker ps

Post-Installation Setup

1. Initialize a Project

Create your first Asantiya project:

# Create a new directory for your project mkdir my-asantiya-project cd my-asantiya-project # Initialize Asantiya configuration asantiya init

This creates a basic deploy.yaml configuration file.

2. Configure Docker (if needed)

Ensure Docker daemon is running:

# Start Docker service (Linux) sudo systemctl start docker sudo systemctl enable docker # Check Docker status sudo systemctl status docker

3. Test with a Simple Application

Create a simple test application to verify everything works:

# Create a simple Dockerfile echo "FROM nginx:alpine" > Dockerfile echo "COPY . /usr/share/nginx/html" >> Dockerfile # Create a simple HTML file echo "<h1>Hello Asantiya!</h1>" > index.html # Deploy locally asantiya deploy

Troubleshooting

Common Issues

1. “Command not found: asantiya”

Solution: Ensure pip installed Asantiya in a directory that’s in your PATH, or use the full path to the asantiya command.

# Find where asantiya was installed pip show asantiya # Add to PATH if needed (Linux/macOS) export PATH="$HOME/.local/bin:$PATH"

2. “Docker not found”

Solution: Ensure Docker is installed and the Docker daemon is running.

# Check if Docker is running docker ps # Start Docker Desktop (Windows/macOS) or Docker service (Linux) sudo systemctl start docker # Linux

3. “Permission denied” errors

Solution: Add your user to the docker group (Linux) or run with appropriate permissions.

# Add user to docker group (Linux) sudo usermod -aG docker $USER # Log out and log back in for changes to take effect

4. Python version conflicts

Solution: Use a virtual environment or ensure you’re using the correct Python version.

# Use specific Python version python3.9 -m pip install asantiya

5. Network Issues

Solution: Use alternative PyPI mirrors or conda for installation.

# Use alternative PyPI mirrors pip install -i https://pypi.douban.com/simple/ asantiya # Or use conda conda install -c conda-forge asantiya

Getting Help

If you encounter issues not covered here:

  1. Check the logs: Asantiya provides detailed error messages
  2. GitHub Issues: Report bugs at github.com/shahid-0/asantiya/issues
  3. Documentation: Refer to other sections of this documentation
  4. Community: Join discussions in the GitHub repository
  5. Email Support: shahiddev91@gmail.com

Development Installation

For developers who want to contribute or modify Asantiya:

# Clone repository git clone https://github.com/shahid-0/asantiya.git cd asantiya # Create virtual environment python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate # Install with development dependencies pip install -e ".[dev]" # Install pre-commit hooks pre-commit install # Run tests pytest

Uninstallation

To remove Asantiya:

# Uninstall from PyPI pip uninstall asantiya # Remove configuration files (optional) rm -rf ~/.asantiya/ rm -f deploy.yaml

Next Steps

Now that Asantiya is installed and verified:

  1. Quick Start Guide - Deploy your first application
  2. Configuration Reference - Learn about configuration options
  3. Examples - See real-world use cases

Ready to deploy? Let’s move on to the Quick Start Guide to deploy your first application with Asantiya.

Last updated on