add Final Infrastructure Setup
This commit is contained in:
commit
7733dde658
174 changed files with 204949 additions and 0 deletions
60
infrastructure/ansible/roles/common/tasks/main.yml
Normal file
60
infrastructure/ansible/roles/common/tasks/main.yml
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
---
|
||||
- name: Update apt cache
|
||||
apt:
|
||||
update_cache: yes
|
||||
cache_valid_time: 3600
|
||||
|
||||
- name: Install base-packets for all nodes
|
||||
apt:
|
||||
name:
|
||||
- ca-certificates
|
||||
- curl
|
||||
- wget
|
||||
- vim
|
||||
- tree
|
||||
- git
|
||||
- unzip
|
||||
- htop
|
||||
- sysstat
|
||||
- net-tools
|
||||
- python3-pip
|
||||
- python3-venv
|
||||
- curl
|
||||
- jq
|
||||
- bc
|
||||
- sysstat
|
||||
- stress-ng
|
||||
state: present
|
||||
|
||||
- name: Install python-libraries (System-Level)
|
||||
apt:
|
||||
name:
|
||||
- python3-pymysql
|
||||
state: present
|
||||
|
||||
- name: Ensure NTP/Timesync is running
|
||||
service:
|
||||
name: systemd-timesyncd
|
||||
state: started
|
||||
enabled: yes
|
||||
|
||||
- name: Stelle sicher, dass das Universe Repository aktiv ist (für OpenJDK 8)
|
||||
apt_repository:
|
||||
repo: "deb http://archive.ubuntu.com/ubuntu/ noble universe"
|
||||
state: present
|
||||
|
||||
- name: Installiere Java 8 (OpenJDK JRE Headless)
|
||||
apt:
|
||||
name: openjdk-8-jre-headless
|
||||
state: present
|
||||
update_cache: yes
|
||||
|
||||
- name: Add hosts to /etc/hosts file on Linux
|
||||
lineinfile:
|
||||
dest: /etc/hosts
|
||||
regexp: "^.*{{ item.value.ip }}.*{{ item.value.hostname }}.*$"
|
||||
line: "{{ item.value.ip }} {{ item.value.hostname }}"
|
||||
state: present
|
||||
when: ansible_os_family != "Windows"
|
||||
become: true
|
||||
with_dict: "{{ configs.host_config }}"
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
127.0.0.1 localhost
|
||||
|
||||
# Automatisch generiert aus host_config
|
||||
{% for hostname, config in configs.host_config.items() %}
|
||||
{{ config.ip }} {{ config.hostname }} {{ hostname }}
|
||||
{% endfor %}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue