Files
RoleForge/dockerfiles/redos/Dockerfile
Sergey Antropoff 01d598eea5 - Админка: настройка pull-реестра (Hub / Harbor / Nexus) в БД, шифрование секретов;
обновлён /admin/config и API для os_registry.
- Molecule/раннер: env из конфигурации, ensure roleforge-os (ensure_roleforge_os.yml),
  os_registry_pull и доработки executors / runner / create.yml.
- /admin/os-images: выбор реестра, buildx (в т.ч. split amd64+arm64 + imagetools),
  опция --no-cache, стрим логов; domain.py: план команд build, ретраи push.
- UI: брендинг (app_name, app_tagline) из app_config через get_ui_branding_context;
  base.xhtml, role-create / role-view, core.js, pages-main, стили.
- Dockerfiles: требование Python ≥3.9 (assert), доработки alt9/astra/debian9/ubuntu20
  и др.; новые Dockerfile.arm64 для centos7/centos8.
- Конфиг: .env.example, config.py, pyproject.toml.
2026-05-06 07:52:29 +03:00

62 lines
2.3 KiB
Docker
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# RED OS с systemd
# Автор: Сергей Антропов
# Сайт: https://devops.org.ru
# https://registry.red-soft.ru/ubi7/ubi/tags
# docker search registry.red-soft.ru/ubi7/ubi
# ВАЖНО: Базовый образ поддерживает только linux/amd64
# Для сборки используйте: docker buildx build --platform linux/amd64
FROM registry.red-soft.ru/ubi7/ubi
ENV container=docker
# Обновляем систему
RUN dnf update -y && dnf upgrade -y
# Устанавливаем systemd и необходимые пакеты
RUN dnf install -y \
systemd \
systemd-sysv \
dbus \
curl \
wget \
nano \
python39 \
python39-pip \
sudo \
&& dnf clean all
RUN alternatives --set python3 /usr/bin/python3.9 2>/dev/null || ln -sf /usr/bin/python3.9 /usr/bin/python3
RUN python3 -c "import sys; assert sys.version_info[:2] >= (3, 9), sys.version"
# Устанавливаем yq (автоопределение архитектуры)
# RUN ARCH=$(uname -m | sed 's/x86_64/amd64/; s/aarch64/arm64/') && \
# wget -qO /usr/local/bin/yq "https://github.com/mikefarah/yq/releases/latest/download/yq_linux_${ARCH}" && \
# chmod +x /usr/local/bin/yq
# Устанавливаем Docker вручную для RED OS
# RUN dnf install -y dnf-plugins-core \
# && dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo \
# && dnf install -y docker-ce docker-ce-cli containerd.io \
# && dnf clean all
# Устанавливаем Docker Compose
# RUN curl -L "https://github.com/docker/compose/releases/latest/download/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose \
# && chmod +x /usr/local/bin/docker-compose
# Настраиваем systemd
RUN systemctl set-default multi-user.target
# Настраиваем sudoers для root и пользователей
RUN echo "root ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers && \
echo "ALL ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/ansible-test
# Создаем пользователя для Ansible
RUN useradd -m -s /bin/bash ansible \
&& echo "ansible ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers
# Команда по умолчанию (система запускается от root для systemd)
STOPSIGNAL SIGRTMIN+3
VOLUME ["/sys/fs/cgroup"]
CMD ["/sbin/init"]