From 669bad6335b61f6481e067e8b2c3fa2936764aa0 Mon Sep 17 00:00:00 2001 From: Iliana Panagopoulou Date: Mon, 20 Feb 2017 15:04:54 +0200 Subject: [PATCH] Added installation for python-yaml On Ubuntu 16.04 LTS python-yaml is not installed, so I added a few lines to help automate the installation of the project. If this gets accepted I can add more distros (e.g not "apt-get" ones) if needed. --- generate_config.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/generate_config.py b/generate_config.py index 2af17d7..c99c964 100755 --- a/generate_config.py +++ b/generate_config.py @@ -2,6 +2,11 @@ import binascii import yaml import os +import platform + +if "Ubuntu" in platform.dist()[0]: + if "16.04" in platfrom.dist()[1]: + os.system("sudo apt install python-yaml") nginx_template = """ server {