From 6fe575b9ac86bd5bd4efc4e7156520639be0ff13 Mon Sep 17 00:00:00 2001 From: Arnaud M Date: Sat, 4 Mar 2023 20:58:18 +0100 Subject: [PATCH] Install python3-pip libffi-dev python3-venv in postinstall instead of during the TP Signed-off-by: Arnaud M --- cloud/training/101.md | 10 ++++++++-- userdata/isen-postinstall.sh | 4 ++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/cloud/training/101.md b/cloud/training/101.md index f934e3f..30bcbc3 100644 --- a/cloud/training/101.md +++ b/cloud/training/101.md @@ -22,12 +22,18 @@ The goal of this workshop is to manipulate and manage OpenStack API from CLI. ## Install `openstack` cli -First, install `openstack` cli from pip: +First, install `openstack` cli from pip, inside a virtual env ``` -apt-get install python3-pip libffi-dev python3-venv +# Create the virtual env python3 -m venv /opt/oscli + +# Enable the virtual env source /opt/oscli/bin/activate + +# Upgrade pip pip install --upgrade pip + +# Install openstack client pip install python-openstackclient ``` diff --git a/userdata/isen-postinstall.sh b/userdata/isen-postinstall.sh index 9dead03..6af57c0 100644 --- a/userdata/isen-postinstall.sh +++ b/userdata/isen-postinstall.sh @@ -44,8 +44,8 @@ apt-get install -y \ software-properties-common \ git \ sshpass \ - tmux -# nginx \ + tmux \ + python3-pip libffi-dev python3-venv title.print "Configuring tmux and plik" wget https://www.arnaudmorin.fr/tmux.conf -O /root/.tmux.conf