fix: replace `GITEA_RUNNER_ACTION_CACHE_DIR` with `GITEA_RUNNER_HOST_WORKDIR_PARENT`
This commit is contained in:
parent
5a8bf4fda0
commit
1cb1426855
|
|
@ -154,7 +154,7 @@ GITEA_RUNNER_JOB_TIMEOUT|`3h`|The maximum time a job can run before it is cancel
|
||||||
GITEA_RUNNER_ENV_VAR_**N**_NAME|`<empty>`|Name of the **N**-th extra environment variable to be passed to Job containers, e.g. `GITEA_RUNNER_ENV_VAR_1_NAME=MY_AUTH_TOKEN`
|
GITEA_RUNNER_ENV_VAR_**N**_NAME|`<empty>`|Name of the **N**-th extra environment variable to be passed to Job containers, e.g. `GITEA_RUNNER_ENV_VAR_1_NAME=MY_AUTH_TOKEN`
|
||||||
GITEA_RUNNER_ENV_VAR_**N**_VALUE|`<empty>`|Value of the **N**-th extra environment variable to be passed to Job containers, e.g. `GITEA_RUNNER_ENV_VAR_1_VALUE=SGVsbG8gbXkgZnJpZW5kIQ==`
|
GITEA_RUNNER_ENV_VAR_**N**_VALUE|`<empty>`|Value of the **N**-th extra environment variable to be passed to Job containers, e.g. `GITEA_RUNNER_ENV_VAR_1_VALUE=SGVsbG8gbXkgZnJpZW5kIQ==`
|
||||||
GITEA_RUNNER_VALID_VOLUME_**N**|`<empty>`|Volumes (including bind mounts) that are allowed to be mounted into job containers. [Glob syntax](https://github.com/gobwas/glob) is supported, e.g. `GITEA_RUNNER_VALID_VOLUME_1=/src/*.json`
|
GITEA_RUNNER_VALID_VOLUME_**N**|`<empty>`|Volumes (including bind mounts) that are allowed to be mounted into job containers. [Glob syntax](https://github.com/gobwas/glob) is supported, e.g. `GITEA_RUNNER_VALID_VOLUME_1=/src/*.json`
|
||||||
GITEA_RUNNER_ACTION_CACHE_DIR|`/data/cache/actions`|Path to cache cloned actions
|
GITEA_RUNNER_HOST_WORKDIR_PARENT|`/data/cache/actions`|The parent directory of a job's working directory. (Path to cache cloned actions)
|
||||||
|
|
||||||
#### Embedded cache server:
|
#### Embedded cache server:
|
||||||
Name|Default Value|Description
|
Name|Default Value|Description
|
||||||
|
|
|
||||||
|
|
@ -186,9 +186,7 @@ ubuntu-20.04:docker://catthehacker/ubuntu:runner-20.04' \
|
||||||
GITEA_RUNNER_GID=1000 \
|
GITEA_RUNNER_GID=1000 \
|
||||||
#
|
#
|
||||||
GITEA_RUNNER_REGISTRATION_TIMEOUT=30\
|
GITEA_RUNNER_REGISTRATION_TIMEOUT=30\
|
||||||
GITEA_RUNNER_REGISTRATION_RETRY_INTERVAL=5s \
|
GITEA_RUNNER_REGISTRATION_RETRY_INTERVAL=5s
|
||||||
#
|
|
||||||
GITEA_RUNNER_ACTION_CACHE_DIR='/data/cache/actions'
|
|
||||||
|
|
||||||
RUN <<EOF
|
RUN <<EOF
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -98,4 +98,4 @@ container:
|
||||||
host:
|
host:
|
||||||
# The parent directory of a job's working directory.
|
# The parent directory of a job's working directory.
|
||||||
# If it's empty, $HOME/.cache/act/ will be used.
|
# If it's empty, $HOME/.cache/act/ will be used.
|
||||||
workdir_parent: '${GITEA_RUNNER_HOST_WORKDIR_PARENT:-}'
|
workdir_parent: '${GITEA_RUNNER_HOST_WORKDIR_PARENT:-/data/cache/actions}'
|
||||||
|
|
|
||||||
|
|
@ -21,17 +21,6 @@ if [[ -f "$INIT_SH_FILE" ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
#################################################
|
|
||||||
# set cache config
|
|
||||||
#################################################
|
|
||||||
# workaround for actions cache dir not being fully configurable
|
|
||||||
# https://gitea.com/gitea/act/src/commit/62abf4fe116865f6edf85d6bce822050dd01ac78/pkg/runner/run_context.go#L360-L371
|
|
||||||
mkdir -p $GITEA_RUNNER_ACTION_CACHE_DIR
|
|
||||||
mkdir -p /tmp/.cache
|
|
||||||
ln -sfn $GITEA_RUNNER_ACTION_CACHE_DIR /tmp/.cache/act
|
|
||||||
export XDG_CACHE_HOME=/tmp/.cache
|
|
||||||
|
|
||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
# render config file
|
# render config file
|
||||||
#################################################
|
#################################################
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue