Last active
November 7, 2019 05:08
-
-
Save hariby/822af5e7e0a20c108b65b045466b8ccc to your computer and use it in GitHub Desktop.
Install Blueqat and Qgate to conda_python3 kernel when starting a SageMaker Notebook instance.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
# OVERVIEW | |
# This script installs a single pip package in a single SageMaker conda environments. | |
# Slightly modified from https://github.com/aws-samples/amazon-sagemaker-notebook-instance-lifecycle-config-samples/blob/master/scripts/install-pip-package-single-environment/on-start.sh | |
sudo -u ec2-user -i <<'EOF' | |
# PARAMETERS | |
PACKAGE=blueqat | |
ENVIRONMENT=python3 | |
source /home/ec2-user/anaconda3/bin/activate "$ENVIRONMENT" | |
pip install "$PACKAGE" | |
wget https://github.com/shinmorino/qgate/raw/gh-pages/packages/0.2/qgate-0.2.1-cp36-cp36m-manylinux1_x86_64.whl | |
pip install qgate-0.2.1-cp36-cp36m-manylinux1_x86_64.whl | |
source /home/ec2-user/anaconda3/bin/deactivate | |
EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment