Deployment

This document provides step-by-step instructions on deploying the AlphaLab package on a cloud platform.

Prerequisites

Before proceeding with the deployment, ensure that you have the following prerequisites in place:

  • Access to a cloud platform (e.g., Amazon Web Services, Google Cloud Platform, Microsoft Azure).

  • Basic knowledge of the cloud platform's interface and virtual machine creation process.

  • A web browser is installed on your local machine.

Step 1: Create a VM

  1. Log in to your cloud platform account.

  2. Navigate to the VM or EC2 instance creation section.

  3. Follow the platform-specific instructions to create a new VM or EC2 instance. AWS, Google Cloud, Azure, DigitalOcean - Droplet

  4. Make sure to select an appropriate operating system and configuration for your needs.

  5. Once the VM is successfully created, take note of its IP address or hostname. You will need this information later.

Step 2: Set Up Python Environment

  1. Connect to the VM using SSH or the platform's remote access interface.

ssh -i key_pair.pem ubuntu@<VM-IP-ADDRESS>

Note: This command is related to AWS EC2 instance.

  1. Install Python on the VM by following the platform-specific instructions. Jump to step 3 (Click on Docker Tab) if you want to use docker instead of setting up python enironment.

Upgrade and update Ubuntu to the latest version

sudo apt update && sudo apt upgrade

Install the required packages

sudo apt install wget build-essential libncursesw5-dev libssl-dev \
libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev libffi-dev zlib1g-dev

Note: The above

Then you can install Python 3.11 using the apt-get package manager

sudo apt install -y python3.11 python3-pip python3-venv
  1. Verify the Python installation by running the following command

python --version

Step 3: Install the quanturf Package

Step 3a: Create python virtual environment using following command

python3 -m venv venv

Step 3b: Activate virtual environment using following command

source venv/bin/activate

Step 3c: Install quanturf package using following command

pip install quanturf

Step 3d: Run jupyterlab using following command. This command starts the JupyterLab server and binds it to port 9000.

python3 -m quanturf jupyterlab

Keep the terminal or command prompt open while the server is running

Step 4: Access JupyterLab on a Web Browser

  1. Open a web browser on your local machine.

  2. In the browser's address bar, enter the following URL: http://<VM-IP-ADDRESS>:9000 Replace <VM-IP-ADDRESS> with the IP address or hostname of the VM from Step 1.

  3. Press Enter to access the JupyterLab interface.

  4. You should now be able to use JupyterLab to work with the quanturf package and perform your desired tasks.

Conclusion

Congratulations! You have successfully deployed the quanturf package on a cloud platform. You can now use JupyterLab through a web browser to utilize the functionality provided by the package.

For more details about deployment, please refer to the accompanying video

Last updated