Add networking

This commit is contained in:
LinuxSquare 2023-07-30 13:01:00 +02:00
parent c34599d749
commit a21f795f24
5 changed files with 30 additions and 5 deletions

View file

@ -2,12 +2,10 @@ applications_mysql_pkgs:
pkg.installed: pkg.installed:
- pkgs: - pkgs:
- mariadb - mariadb
- mariadb-client
- mariadb-openrc
applications_mysql_enable: applications_mysql_enable:
service.enabled:
- name: mariadb
- require:
- applications_mysql_pkgs
file.directory: file.directory:
- name: /var/lib/mysql - name: /var/lib/mysql
- create: False - create: False
@ -19,3 +17,7 @@ applications_mysql_enable:
- group - group
- require: - require:
- applications_mysql_pkgs - applications_mysql_pkgs
service.enabled:
- name: mariadb
- require:
- applications_mysql_pkgs

View file

@ -2,6 +2,7 @@ applications_podman_pkgs:
pkg.installed: pkg.installed:
- pkgs: - pkgs:
- podman - podman
- podman-openrc
applications_podman_enable: applications_podman_enable:
service.enabled: service.enabled:

View file

@ -1,7 +1,7 @@
applications_ssh_pkgs: applications_ssh_pkgs:
pkg.installed: pkg.installed:
- pkgs: - pkgs:
- openssh - openssh-server
applications_ssh_add_keys: applications_ssh_add_keys:
file.managed: file.managed:

View file

@ -0,0 +1,2 @@
auto eth0
iface eth0 inet dhcp

20
system/network.sls Normal file
View file

@ -0,0 +1,20 @@
include:
- .base
system_network_interfaces:
file.managed:
- name: /etc/network/interfaces
- source: salt://{{ tpldir }}/files/network_interfaces
- user: root
- group: root
- mode: '0644'
- require:
- system_base_pkgs
system_network_service_reload:
service.running:
- name: networking
- enable: true
- reload: true
- watch:
- system_network_interfaces