Initial commit

This commit is contained in:
2024-11-24 20:30:42 +01:00
commit 8b965d1f54
3 changed files with 40 additions and 0 deletions

19
Dockerfile Normal file
View File

@@ -0,0 +1,19 @@
FROM public.ecr.aws/docker/library/node:22-alpine3.20
# PIPX Paths
ENV PATH=/root/.local/bin:$PATH
# Install git for gitea actions and ansible
RUN <<EOF
set -e
apk add --no-cache bash curl python3 pipx git rsync unzip openssh
pipx install --include-deps ansible
EOF
ENV PY_COLOR="1"
ENV ANSIBLE_FORCE_COLOR="1"
COPY entrypoint.sh .
RUN chmod +x /usr/src/entrypoint.sh
ENTRYPOINT ["ash","-c","/usr/src/entrypoint.sh"]

15
action.yml Normal file
View File

@@ -0,0 +1,15 @@
name: Run ansible playbook
description: An ansible runner
author: Skydust
# Define your inputs here.
inputs:
path:
description: The playbook's path
required: true
runs:
using: docker
image: Dockerfile
env:
INPUT_PATH: ${{ inputs.path }}

6
entrypoint.sh Normal file
View File

@@ -0,0 +1,6 @@
#!/usr/bin/env ash
set -e
ansible-playbook "$INPUT_PATH" -vv
exit 0