feat: add SSH login information and dotfiles status check to hello.py; include OpenSSH server tasks in Ansible configuration
Some checks failed
Nix Format Check / check-format (push) Failing after 39s

This commit is contained in:
2025-03-10 19:05:18 +01:00
parent 6c095843ba
commit 7315809914
6 changed files with 181 additions and 14 deletions

View File

@@ -22,6 +22,10 @@
ansible.builtin.import_tasks: tasks/global/ollama.yml
become: true
- name: Include OpenSSH Server tasks
ansible.builtin.import_tasks: tasks/global/openssh-server.yml
become: true
- name: Ensure common packages are installed
ansible.builtin.package:
name:
@@ -31,9 +35,11 @@
- trash-cli
- curl
- wget
# Python is used for the dotfiles CLI tools
- python3
- python3-pip
- python3-venv
- lastlog2 # Used for displaying last login information
state: present
become: true

View File

@@ -0,0 +1,22 @@
---
- name: Ensure openssh-server is installed
ansible.builtin.package:
name: openssh-server
state: present
- name: Ensure SSH server configuration is proper
ansible.builtin.template:
src: templates/sshd_config.j2
dest: /etc/ssh/sshd_config
owner: root
group: root
mode: '0644'
validate: '/usr/sbin/sshd -t -f %s'
notify: Restart SSH service
register: ssh_config
- name: Ensure SSH service is enabled and running
ansible.builtin.service:
name: ssh
state: started
enabled: true