feat(ci): использовать готовый локальный образ homelab-ansible:latest, поддержать смену домена в .env

This commit is contained in:
karpenok committed 2026-11-08 13:15:20 +07:00
1 parent cd5ffb9804
commit 09f5afe564
3 files changed
+19 -10

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
FROM ubuntu:24.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y --no-install-recommends \
git \
openssh-client \
ansible-core \
python3 \
sshpass \
ca-certificates \
curl \
&& ansible-galaxy collection install ansible.posix \
&& rm -rf /var/lib/apt/lists/*
+2 -9
View File
@@ -11,6 +11,8 @@ on:
jobs:
install:
runs-on: homelab
container:
image: homelab-ansible:latest
timeout-minutes: 30
steps:
- name: Запустить плейбук NetBird
@@ -28,14 +30,6 @@ jobs:
exit 1
fi
if [ "$(id -u)" -eq 0 ]; then
apt-get update
apt-get install -y git openssh-client ansible-core python3 sshpass
else
sudo apt-get update
sudo apt-get install -y git openssh-client ansible-core python3 sshpass
fi
rm -rf "${HOME}/homelab-infra"
git clone https://gitea.gunihome.ru/karpenok/homelab-infra.git "${HOME}/homelab-infra"
sha="${GITHUB_SHA:-${GITEA_SHA:-}}"
@@ -50,7 +44,6 @@ jobs:
trap 'rm -f "${HOME}/.ssh/id_ed25519"' EXIT
cd "${HOME}/homelab-infra"
ansible-galaxy collection install -r requirements.yml
ansible-playbook playbooks/site.yml \
-i inventories/prod/hosts.yml \
+2 -1
View File
@@ -84,7 +84,8 @@
mode: "0600"
no_log: true
notify: Перезапустить NetBird
when: not netbird_env.stat.exists
tags:
- config
- name: Положить манифест панели
ansible.builtin.copy: