Create a custom Ansible playbook for Ubuntu and Debian servers in just a few clicks.
---
- hosts: all
become: yes
tasks:
- name: Configure DNS
resolv:
nameservers:
- 8.8.8.8
- 1.1.1.1
- name: Configure NTP
ntp:
servers:
- pool.ntp.org
- ntp.ubuntu.com
- name: Allow SSH through UFW
ufw:
rule: allow
name: OpenSSH
- name: Ensure correct OS version
debug:
msg: "Running on ubuntu-2404"