fix linter and bump python CI versions

format-files
chatton 3 years ago
parent bd7d73e40b
commit 82bc12046b

@ -32,7 +32,7 @@ jobs:
mv tests/hosts.ini ./hosts.ini
- uses: actions/setup-python@v4
with:
python-version: 3.8.9
python-version: 3.11.4
- name: Install test dependencies.
run: pip install -r requirements.txt
- name: Install ansible dependencies.

@ -32,7 +32,7 @@ jobs:
mv tests/hosts.ini ./hosts.ini
- uses: actions/setup-python@v4
with:
python-version: 3.8.9
python-version: 3.11.4
- name: Install test dependencies.
run: pip install -r requirements.txt
- name: Delete Linode Instance

@ -19,7 +19,7 @@ jobs:
uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.8.9
python-version: 3.11.4
- name: Create Vault Key
run: echo "${{ secrets.VAULT_PASSWORD }}" > ~/.vault-key
- name: Install dependencies
@ -34,7 +34,7 @@ jobs:
uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.8.9
python-version: 3.11.4
- name: Install dependencies
run: make deps
- name: Format code

@ -9,7 +9,8 @@
tags: [always]
tasks:
- ansible.builtin.include_role:
- name: Backup Directories.
ansible.builtin.include_role:
name: backup_directory
with_items: "{{ backup_directories }}"
loop_control:

@ -6,6 +6,7 @@
community.general.archive:
path: "{{ backup.path }}"
dest: /tmp/backup.tar.gz
mode: "0755"
- name: Upload backups to S3
amazon.aws.aws_s3:
@ -20,6 +21,6 @@
permission: "{{ docker_backup_aws_s3_permissions }}"
- name: Remove local backup.
file:
ansible.builtin.file:
path: /tmp/backup.tar.gz
state: absent

@ -70,14 +70,14 @@
loop_var: portainer_stack
- name: Install Ansible pull
tags: [ "cron" ]
tags: ["cron"]
ansible.builtin.pip:
name:
- ansible
# TODO: need to specify ansible pull directly, it doesn't find it when it's in PATH
- name: Ensure Nightly Cron Backups
tags: [ "cron" ]
tags: ["cron"]
ansible.builtin.cron:
name: backup docker volumes (nightly)
weekday: "*"
@ -89,16 +89,3 @@
-U https://github.com/chatton/ansible-homelab playbooks/backup-docker-volumes.yml -e schedule=nightly >> ~/logs/nightly.log 2>&1
cron_file: ansible_nightly_docker_volume_backup
state: present
- name: Ensure Monthly Cron Backups
tags: [ "cron" ]
ansible.builtin.cron:
name: backup docker volumes (monthly)
month: "*"
day: "0"
user: "{{ homelab_user }}"
job: >
{{ ansible_pull_path }}
-U https://github.com/chatton/ansible-homelab playbooks/backup-docker-volumes.yml -e schedule=monthly >> ~/logs/monthly.log 2>&1
cron_file: ansible_monthly_docker_volume_backup
state: present

@ -43,14 +43,14 @@
mode: 0644
- name: Disable password authentication for root.
lineinfile:
ansible.builtin.lineinfile:
path: /etc/ssh/sshd_config
state: present
regexp: '^#?PermitRootLogin'
line: 'PermitRootLogin prohibit-password'
- name: Disable password authentication for users.
lineinfile:
ansible.builtin.lineinfile:
path: /etc/ssh/sshd_config
state: present
regexp: '^#?PasswordAuthentication'

Loading…
Cancel
Save