From f8f15d91de46ddc528d669e6ecf94fedfce1e757 Mon Sep 17 00:00:00 2001 From: Marcello Calisto Date: Sat, 9 Sep 2023 15:11:55 +0200 Subject: [PATCH] =?UTF-8?q?Files=20gel=C3=B6scht?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- KN03/cloud-init-db.yaml | 18 --------------- KN03/cloud-init-ssh.yaml | 16 -------------- KN03/cloud-init-web.yaml | 47 ---------------------------------------- 3 files changed, 81 deletions(-) delete mode 100644 KN03/cloud-init-db.yaml delete mode 100644 KN03/cloud-init-ssh.yaml delete mode 100644 KN03/cloud-init-web.yaml diff --git a/KN03/cloud-init-db.yaml b/KN03/cloud-init-db.yaml deleted file mode 100644 index a28a11f..0000000 --- a/KN03/cloud-init-db.yaml +++ /dev/null @@ -1,18 +0,0 @@ -#cloud-config -users: - - name: ubuntu - sudo: ALL=(ALL) NOPASSWD:ALL - groups: users, admin - home: /home/ubuntu - shell: /bin/bash - ssh_authorized_keys: - - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC0WGP1EZykEtv5YGC9nMiPFW3U3DmZNzKFO5nEu6uozEHh4jLZzPNHSrfFTuQ2GnRDSt+XbOtTLdcj26+iPNiFoFha42aCIzYjt6V8Z+SQ9pzF4jPPzxwXfDdkEWylgoNnZ+4MG1lNFqa8aO7F62tX0Yj5khjC0Bs7Mb2cHLx1XZaxJV6qSaulDuBbLYe8QUZXkMc7wmob3PM0kflfolR3LE7LResIHWa4j4FL6r5cQmFlDU2BDPpKMFMGUfRSFiUtaWBNXFOWHQBC2+uKmuMPYP4vJC9sBgqMvPN/X2KyemqdMvdKXnCfrzadHuSSJYEzD64Cve5Zl9yVvY4AqyBD aws-key -ssh_pwauth: false -disable_root: false -package_update: true -packages: - - mariadb-server -runcmd: - - sudo mysql -sfu root -e "GRANT ALL ON *.* TO 'admin'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION;" - - sudo sed -i 's/127.0.0.1/0.0.0.0/g' /etc/mysql/mariadb.conf.d/50-server.cnf - - sudo systemctl restart mariadb.service diff --git a/KN03/cloud-init-ssh.yaml b/KN03/cloud-init-ssh.yaml deleted file mode 100644 index f0703b8..0000000 --- a/KN03/cloud-init-ssh.yaml +++ /dev/null @@ -1,16 +0,0 @@ -#cloud-config -users: - - name: ubuntu - sudo: ALL=(ALL) NOPASSWD:ALL - groups: users, admin - home: /home/ubuntu - shell: /bin/bash - ssh_authorized_keys: - - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC0WGP1EZykEtv5YGC9nMiPFW3U3DmZNzKFO5nEu6uozEHh4jLZzPNHSrfFTuQ2GnRDSt+XbOtTLdcj26+iPNiFoFha42aCIzYjt6V8Z+SQ9pzF4jPPzxwXfDdkEWylgoNnZ+4MG1lNFqa8aO7F62tX0Yj5khjC0Bs7Mb2cHLx1XZaxJV6qSaulDuBbLYe8QUZXkMc7wmob3PM0kflfolR3LE7LResIHWa4j4FL6r5cQmFlDU2BDPpKMFMGUfRSFiUtaWBNXFOWHQBC2+uKmuMPYP4vJC9sBgqMvPN/X2KyemqdMvdKXnCfrzadHuSSJYEzD64Cve5Zl9yVvY4AqyBD aws-key - - ssh-rsa zweiterkeynMiPFW3U3DmZNzKFO5nEu6uozEHh4jLZzPNHSrfFTuQ2GnRDSt+XbOtTLdcj26+iPNiFoFha42aCIzYjt6V8Z+SQ9pzF4jPPzxwXfDdkEWylgoNnZ+4MG1lNFqa8aO7F62tX0Yj5khjC0Bs7Mb2cHLx1XZaxJV6qSaulDuBbLYe8QUZXkMc7wmob3PM0kflfolR3LE7LResIHWa4j4FL6r5cQmFlDU2BDPpKMFMGUfRSFiUtaWBNXFOWHQBC2+uKmuMPYP4vJC9sBgqMvPN/X2KyemqdMvdKXnCfrzadHuSSJYEzD64Cve5Zl9yVvY4AqyBD aws-key -ssh_pwauth: false -disable_root: false -package_update: true -packages: - - curl - - wget diff --git a/KN03/cloud-init-web.yaml b/KN03/cloud-init-web.yaml deleted file mode 100644 index 5a7eb98..0000000 --- a/KN03/cloud-init-web.yaml +++ /dev/null @@ -1,47 +0,0 @@ -#cloud-config -users: - - name: ubuntu - sudo: ALL=(ALL) NOPASSWD:ALL - groups: users, admin - home: /home/ubuntu - shell: /bin/bash - ssh_authorized_keys: - - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC0WGP1EZykEtv5YGC9nMiPFW3U3DmZNzKFO5nEu6uozEHh4jLZzPNHSrfFTuQ2GnRDSt+XbOtTLdcj26+iPNiFoFha42aCIzYjt6V8Z+SQ9pzF4jPPzxwXfDdkEWylgoNnZ+4MG1lNFqa8aO7F62tX0Yj5khjC0Bs7Mb2cHLx1XZaxJV6qSaulDuBbLYe8QUZXkMc7wmob3PM0kflfolR3LE7LResIHWa4j4FL6r5cQmFlDU2BDPpKMFMGUfRSFiUtaWBNXFOWHQBC2+uKmuMPYP4vJC9sBgqMvPN/X2KyemqdMvdKXnCfrzadHuSSJYEzD64Cve5Zl9yVvY4AqyBD aws-key -ssh_pwauth: false -disable_root: false -package_update: true -packages: - - apache2 - - curl - - wget - - php - - libapache2-mod-php - - php-mysqli - - adminer -write_files: - - content: | - - path: /var/www/html/info.php - permissions: '0644' - - content: | - connect_error) { - die("Connection failed: " . $conn->connect_error); - } - $sql = "select Host, User from mysql.user;"; - $result = $conn->query($sql); - while($row = $result->fetch_assoc()){ - echo($row["Host"] . " / " . $row["User"] . "
"); - } - ?> - path: /var/www/html/db.php - permissions: '0644' -runcmd: - - sudo a2enconf adminer - - sudo systemctl restart apache2 -