Skip to content

Commit 5489761

Browse files
committed
feat(release): 2.328.0
1 parent 39651ff commit 5489761

File tree

9 files changed

+52
-12
lines changed

9 files changed

+52
-12
lines changed

Dockerfile

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ FROM debian:bookworm-slim
22

33
LABEL maintainer="Scalified <[email protected]>"
44

5-
ARG ACTIONS_RUNNER_VERSION="2.327.1"
5+
ARG ACTIONS_RUNNER_VERSION="2.328.0"
66

77
ENV DEBIAN_FRONTEND=noninteractive
88
ENV RUNNER_ALLOW_RUNASROOT="1"
@@ -11,6 +11,7 @@ RUN apt update && \
1111
apt install -y --no-install-recommends \
1212
ca-certificates \
1313
curl \
14+
cron \
1415
wget \
1516
git \
1617
gnupg \
@@ -28,7 +29,8 @@ RUN mkdir -p /etc/apt/keyrings && \
2829

2930
RUN apt update && \
3031
apt install -y --no-install-recommends \
31-
docker-ce && \
32+
docker-ce \
33+
docker-buildx-plugin && \
3234
apt clean && \
3335
rm -rf /var/lib/apt/lists/*
3436

@@ -38,8 +40,7 @@ RUN curl -sSLo actions-runner.tar.gz "https://github.com/actions/runner/releases
3840
&& tar -zxvf actions-runner.tar.gz \
3941
&& rm -rf actions-runner.tar.gz
4042

41-
COPY etc /etc/
42-
COPY usr /usr/
43+
COPY rootfs /
4344

44-
ENTRYPOINT ["supervisord", "-c", "/etc/supervisord.conf"]
45+
ENTRYPOINT ["/usr/local/bin/entrypoint"]
4546

README.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,19 +21,21 @@ docker run \
2121
--hostname ghar-runner-1 \
2222
--restart unless-stopped \
2323
--privileged \
24+
-e "DOCKER_PRUNE_SCHEDULE=0 0 * * 1" \
2425
-e URL=https://github.com/$GITHUB_ORG_NAME \
2526
-e TOKEN=AAAAAAAAAAAAAAAAAAAAAAAAAAAAA \
2627
-e LABELS=ghar-runner-1 \
2728
-e GROUP=group-1 \
2829
scalified/github-actions-runner
2930
```
3031

31-
| Environment Variable | Description |
32-
|----------------------|---------------------------------------------------------------------|
33-
| `URL` | **GitHub** organization URL: `https://github.com/$GITHUB_ORG_NAME` |
34-
| `TOKEN` | **GitHub** Actions Runner token displayed after adding a new runner |
35-
| `LABELS` | Labels assigned to the **GitHub Actions Runner** |
36-
| `GROUP` | **GitHub** Actions Runner group |
32+
| Environment Variable | Description |
33+
|-------------------------|--------------------------------------------------------------------------|
34+
| `DOCKER_PRUNE_SCHEDULE` | **Cron** schedule for auto docker system prune ("37 4 2 * *" by default) |
35+
| `URL` | **GitHub** organization URL: `https://github.com/$GITHUB_ORG_NAME` |
36+
| `TOKEN` | **GitHub** Actions Runner token displayed after adding a new runner |
37+
| `LABELS` | Labels assigned to the **GitHub Actions Runner** |
38+
| `GROUP` | **GitHub** Actions Runner group |
3739

3840

3941
---

etc/supervisor.d/actions-runner.ini renamed to rootfs/etc/supervisor.d/actions-runner.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[program:actions-runner]
22
command=actions-runner
3-
priority=3
3+
priority=4
44
autostart=true
55
autorestart=true
66
startsecs=15

rootfs/etc/supervisor.d/cron.ini

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
[program:cron]
2+
command=cron -f -L 0
3+
priority=3
4+
autostart=true
5+
autorestart=true
6+
startsecs=15
7+
stdout_logfile=/dev/stdout
8+
stdout_logfile_maxbytes=0
9+
stdout_logfile_backups=0
10+
stdout_capture_maxbytes=0
11+
stdout_events_enabled=true
12+
stdout_syslog=false
13+
stderr_logfile=/dev/stderr
14+
stderr_logfile_maxbytes=0
15+
stderr_logfile_backups=0
16+
stderr_capture_maxbytes=0
17+
stderr_events_enabled=true
18+
stderr_syslog=false
19+
File renamed without changes.
File renamed without changes.
File renamed without changes.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
#!/bin/sh
2+
3+
prune() {
4+
echo "[INFO]: Pruning Docker System"
5+
docker system prune --all --volumes --force
6+
echo "[INFO]: Docker System Prunned"
7+
}
8+
9+
prune
10+

rootfs/usr/local/bin/entrypoint

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/bin/sh
2+
3+
DOCKER_PRUNE_SCHEDULE="${DOCKER_PRUNE_SCHEDULE:-37 4 2 * *}"
4+
5+
echo "${DOCKER_PRUNE_SCHEDULE} root /usr/local/bin/docker-system-prune > /proc/1/fd/1 2>/proc/1/fd/2" > "/etc/cron.d/docker-system-prune"
6+
7+
supervisord -c "/etc/supervisord.conf"
8+

0 commit comments

Comments
 (0)