From e3c8f6ba7119e2f94a6de3084cc117a5b716de58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20MARQUET?= <72651575+BreizhHardware@users.noreply.github.com> Date: Tue, 13 Jan 2026 11:59:00 +0100 Subject: [PATCH] Obisidian vault auto-backup: 13-01-2026 11:59:00 on . 1 files edited --- .../CIPA4/Cloud Computing Cours 2.md | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/ISEN/Cloud Computing/CIPA4/Cloud Computing Cours 2.md b/ISEN/Cloud Computing/CIPA4/Cloud Computing Cours 2.md index 79e9514..f29c51b 100644 --- a/ISEN/Cloud Computing/CIPA4/Cloud Computing Cours 2.md +++ b/ISEN/Cloud Computing/CIPA4/Cloud Computing Cours 2.md @@ -68,3 +68,27 @@ debian@myvm01:~$ ip a ```bash openstack server create --image 'Debian 12' --flavor small --network private --key-name isen --user-data postinstall.sh myvm01 ``` + +### Check the result +Q: what is the name of the service running inside your instance that execute this `user-data` script? +cloud-init + +Q: from which url this service retrieve the script? +http://169.254.169.254/openstack/2012-08-10/user_data + +## demo-flask +```bash +#!/bin/bash + +sudo apt update + +sudo apt install -y python3-pip git + +git clone https://github.com/arnaudmorin/demo-flask.git /home/debian/demo-flask + +pip3 install -r /home/debian/demo-flask/requirements.txt + +nohup /home/debian/demo-flask/start.sh & + +echo "Hello from my instance" > /var/log/postinstall.log +``` \ No newline at end of file