ansible-devspace/Dockerfile

63 lines
1.7 KiB
Text
Raw Normal View History

FROM python:3.13.1-bookworm
squash ci: when hadolint: DL3047 chore(deps): update dependency jinja2 to v2.11.3 (#1) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency pykeepass to v4.1.0 (#2) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> Syntax Test chore(deps): update dependency jinja2 to v3.1.4 (#3) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> t d fdgh 3 r dd dff ff df ff dfdf ff todo dd dd ff ff chore(deps): update woodpeckerci/plugin-git docker tag to v2.5.1 (#5) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> pip extra pykeepass==4.0.3 ff ff f apackages dd ff ff ff --root-user-action--root-user-action dd ff ff ff gg ff chore(deps): update dependency ansible-dev-tools to v24.7.2 (#6) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible-manage-lvm to v0.2.12 (#7) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency community.crypto to v2.21.1 (#8) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update docker docker tag to v27.1.0 (#9) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible_role_gitea to v3.5.0 (#10) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ffd d chore(deps): update docker docker tag to v27.1.1 (#11) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ff f dd dd ff dsfsa dd chore(deps): update dependency pykeepass to v4.1.0 (#12) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> H
2024-07-09 22:35:14 +02:00
# lese secrets von pipeline ein
RUN --mount=type=secret,id=GITUSERPW \
--mount=type=secret,id=GITUSER \
export GITUSERPW=$(cat /run/secrets/GITUSERPW) && \
export GITUSER=$(cat /run/secrets/GITUSER)
squash ci: when hadolint: DL3047 chore(deps): update dependency jinja2 to v2.11.3 (#1) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency pykeepass to v4.1.0 (#2) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> Syntax Test chore(deps): update dependency jinja2 to v3.1.4 (#3) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> t d fdgh 3 r dd dff ff df ff dfdf ff todo dd dd ff ff chore(deps): update woodpeckerci/plugin-git docker tag to v2.5.1 (#5) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> pip extra pykeepass==4.0.3 ff ff f apackages dd ff ff ff --root-user-action--root-user-action dd ff ff ff gg ff chore(deps): update dependency ansible-dev-tools to v24.7.2 (#6) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible-manage-lvm to v0.2.12 (#7) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency community.crypto to v2.21.1 (#8) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update docker docker tag to v27.1.0 (#9) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible_role_gitea to v3.5.0 (#10) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ffd d chore(deps): update docker docker tag to v27.1.1 (#11) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ff f dd dd ff dsfsa dd chore(deps): update dependency pykeepass to v4.1.0 (#12) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> H
2024-07-09 22:35:14 +02:00
ENV DEBIAN_FRONTEND=noninteractive
2024-07-30 10:40:16 +02:00
# nötig damit die ansible-tools gefunden werden
2024-07-30 11:11:07 +02:00
ENV PATH="$PATH:/home/ansible-dev/.local/bin"
2024-07-30 10:40:16 +02:00
squash ci: when hadolint: DL3047 chore(deps): update dependency jinja2 to v2.11.3 (#1) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency pykeepass to v4.1.0 (#2) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> Syntax Test chore(deps): update dependency jinja2 to v3.1.4 (#3) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> t d fdgh 3 r dd dff ff df ff dfdf ff todo dd dd ff ff chore(deps): update woodpeckerci/plugin-git docker tag to v2.5.1 (#5) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> pip extra pykeepass==4.0.3 ff ff f apackages dd ff ff ff --root-user-action--root-user-action dd ff ff ff gg ff chore(deps): update dependency ansible-dev-tools to v24.7.2 (#6) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible-manage-lvm to v0.2.12 (#7) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency community.crypto to v2.21.1 (#8) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update docker docker tag to v27.1.0 (#9) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible_role_gitea to v3.5.0 (#10) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ffd d chore(deps): update docker docker tag to v27.1.1 (#11) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ff f dd dd ff dsfsa dd chore(deps): update dependency pykeepass to v4.1.0 (#12) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> H
2024-07-09 22:35:14 +02:00
# hadolint ignore=DL3008
RUN apt-get update \
&& apt-get -y --no-install-recommends install \
vim \
2024-07-25 23:13:58 +02:00
keychain \
squash ci: when hadolint: DL3047 chore(deps): update dependency jinja2 to v2.11.3 (#1) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency pykeepass to v4.1.0 (#2) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> Syntax Test chore(deps): update dependency jinja2 to v3.1.4 (#3) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> t d fdgh 3 r dd dff ff df ff dfdf ff todo dd dd ff ff chore(deps): update woodpeckerci/plugin-git docker tag to v2.5.1 (#5) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> pip extra pykeepass==4.0.3 ff ff f apackages dd ff ff ff --root-user-action--root-user-action dd ff ff ff gg ff chore(deps): update dependency ansible-dev-tools to v24.7.2 (#6) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible-manage-lvm to v0.2.12 (#7) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency community.crypto to v2.21.1 (#8) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update docker docker tag to v27.1.0 (#9) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible_role_gitea to v3.5.0 (#10) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ffd d chore(deps): update docker docker tag to v27.1.1 (#11) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ff f dd dd ff dsfsa dd chore(deps): update dependency pykeepass to v4.1.0 (#12) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> H
2024-07-09 22:35:14 +02:00
tmux \
htop \
git \
dnsutils \
mc \
ca-certificates \
tree \
wget \
curl \
whois \
net-tools \
apt-transport-https \
moreutils \
acl \
ripgrep \
pwgen \
bc \
jq \
sudo \
2024-08-12 10:23:05 +02:00
sshpass \
2024-09-27 18:58:37 +02:00
shellcheck \
2024-07-25 23:17:16 +02:00
&& rm -rf /var/lib/apt/lists/* /var/tmp/* /tmp/* requirements.txt requirements.yaml \
squash ci: when hadolint: DL3047 chore(deps): update dependency jinja2 to v2.11.3 (#1) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency pykeepass to v4.1.0 (#2) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> Syntax Test chore(deps): update dependency jinja2 to v3.1.4 (#3) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> t d fdgh 3 r dd dff ff df ff dfdf ff todo dd dd ff ff chore(deps): update woodpeckerci/plugin-git docker tag to v2.5.1 (#5) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> pip extra pykeepass==4.0.3 ff ff f apackages dd ff ff ff --root-user-action--root-user-action dd ff ff ff gg ff chore(deps): update dependency ansible-dev-tools to v24.7.2 (#6) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible-manage-lvm to v0.2.12 (#7) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency community.crypto to v2.21.1 (#8) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update docker docker tag to v27.1.0 (#9) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> chore(deps): update dependency ansible_role_gitea to v3.5.0 (#10) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ffd d chore(deps): update docker docker tag to v27.1.1 (#11) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> ff f dd dd ff dsfsa dd chore(deps): update dependency pykeepass to v4.1.0 (#12) Co-authored-by: Renovate Bot <renovate@mgrote.net> Co-committed-by: Renovate Bot <renovate@mgrote.net> H
2024-07-09 22:35:14 +02:00
&& apt-get clean
2024-07-25 23:13:58 +02:00
# Update the package list, install sudo, create a non-root user, and grant password-less sudo permissions
# https://dev.to/izackv/running-a-docker-container-with-a-custom-non-root-user-syncing-host-and-container-permissions-26mb
# hadolint ignore=DL3008
2024-07-30 11:18:05 +02:00
RUN addgroup --gid 1000 ansible-dev && \
2024-07-30 11:21:23 +02:00
adduser --uid 1000 --gid 1000 --disabled-password --gecos "" ansible-dev && \
2024-07-30 11:11:07 +02:00
echo 'ansible-dev ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
# Set the non-root user as the default user
2024-07-30 11:11:07 +02:00
USER ansible-dev
2024-07-30 11:11:07 +02:00
WORKDIR /home/ansible-dev/
2024-12-30 20:50:36 +01:00
RUN cat /run/secrets/GITUSERPW
RUN echo https://$GITUSER:$GITUSERPW@git.mgrote.net/mg/dotfiles ~/dotfiles
2024-12-30 20:25:10 +01:00
2024-07-25 23:17:16 +02:00
# dotfiles, see: https://git.mgrote.net/mg/dotfiles/raw/branch/master/scripts/setup_minimal.sh
2024-12-30 20:13:43 +01:00
# hadolint ignore=DL3001,SC1083
RUN git clone https://$GITUSER:$GITUSERPW@git.mgrote.net/mg/dotfiles ~/dotfiles
2024-07-29 15:59:43 +02:00
2024-07-30 20:30:11 +02:00
COPY --chown=ansible-dev:ansible-dev start_tmux.sh .
2024-09-13 18:52:01 +02:00
ENTRYPOINT []