This commit is contained in:
Alex Devera 2025-02-25 10:19:03 +03:00
parent 1bdad58eb7
commit ff8082c943

View file

@ -1,4 +1,3 @@
---
- name: Update repositories and upgrade packages on Ubuntu - name: Update repositories and upgrade packages on Ubuntu
hosts: all hosts: all
become: yes become: yes
@ -6,10 +5,11 @@
- name: Update apt cache - name: Update apt cache
apt: apt:
update_cache: yes update_cache: yes
cache_valid_time: 3600 # Обновлять кеш не чаще, чем раз в час
- name: Upgrade all packages to the latest version - name: Upgrade all packages to the latest version
apt: apt:
upgrade: dist full_upgrade: yes # Более надежная альтернатива `upgrade: dist`
- name: Remove unnecessary packages - name: Remove unnecessary packages
apt: apt:
@ -19,9 +19,9 @@
- name: Send notify to Telegram - name: Send notify to Telegram
community.general.telegram: community.general.telegram:
token: '5909855740:AAGLftkWmQl0XTLHLo1PcI87HHXoU7eEAGM' token: '5909855740:AAGLftkWmQl0XTLHLo1PcI87HHXoU7eEAGM'
api_args: data:
chat_id: 222227130 chat_id: 222227130
parse_mode: "markdown" parse_mode: "Markdown"
text: "Your precious application has been deployed: https://example.com" text: "Your precious application has been deployed: https://example.com"
disable_web_page_preview: true disable_web_page_preview: true
disable_notification: true disable_notification: true