Initial commit
This commit is contained in:
19
Dockerfile
Normal file
19
Dockerfile
Normal 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
15
action.yml
Normal 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
6
entrypoint.sh
Normal file
@@ -0,0 +1,6 @@
|
||||
#!/usr/bin/env ash
|
||||
|
||||
set -e
|
||||
ansible-playbook "$INPUT_PATH" -vv
|
||||
|
||||
exit 0
|
||||
Reference in New Issue
Block a user