cluster

Infrastructure files for Nordgedanken and Midnightthoughts.
git clone git://archive.git.mtrnord.blog/MTRNord/cluster.git
Log | Files | Refs | README

cm.yaml (4483B)


      1 apiVersion: v1
      2 kind: ConfigMap
      3 metadata:
      4   name: runner-config
      5 data:
      6   config.yaml: |
      7     log:
      8       # The level of logging, can be trace, debug, info, warn, error, fatal
      9       level: info
     10 
     11     runner:
     12       # Where to store the registration result.
     13       file: .runner
     14       # Execute how many tasks concurrently at the same time.
     15       capacity: 1
     16       # Extra environment variables to run jobs.
     17       # envs:
     18       #   A_TEST_ENV_NAME_1: a_test_env_value_1
     19       #   A_TEST_ENV_NAME_2: a_test_env_value_2
     20       # Extra environment variables to run jobs from a file.
     21       # It will be ignored if it's empty or the file doesn't exist.
     22       env_file: .env
     23       # The timeout for a job to be finished.
     24       # Please note that the Forgejo instance also has a timeout (3h by default) for the job.
     25       # So the job could be stopped by the Forgejo instance if it's timeout is shorter than this.
     26       timeout: 3h
     27       # Whether skip verifying the TLS certificate of the Forgejo instance.
     28       insecure: false
     29       # The timeout for fetching the job from the Forgejo instance.
     30       fetch_timeout: 5s
     31       # The interval for fetching the job from the Forgejo instance.
     32       fetch_interval: 2s
     33       # The labels of a runner are used to determine which jobs the runner can run, and how to run them.
     34       # Like: ["macos-arm64:host", "ubuntu-latest:docker://node:16-bullseye", "ubuntu-22.04:docker://node:16-bullseye"]
     35       # If it's empty when registering, it will ask for inputting labels.
     36       # If it's empty when execute `deamon`, will use labels in `.runner` file.
     37       labels: []
     38 
     39     cache:
     40       # Enable cache server to use actions/cache.
     41       enabled: true
     42       # The directory to store the cache data.
     43       # If it's empty, the cache data will be stored in $HOME/.cache/actcache.
     44       dir: /data
     45       # The host of the cache server.
     46       # It's not for the address to listen, but the address to connect from job containers.
     47       # So 0.0.0.0 is a bad choice, leave it empty to detect automatically.
     48       host: ""
     49       # The port of the cache server.
     50       # 0 means to use a random available port.
     51       port: 0
     52       # The external cache server URL. Valid only when enable is true.
     53       # If it's specified, act_runner will use this URL as the ACTIONS_CACHE_URL rather than start a server by itself.
     54       # The URL should generally end with "/".
     55       external_server: ""
     56 
     57     container:
     58       # Specifies the network to which the container will connect.
     59       # Could be host, bridge or the name of a custom network.
     60       # If it's empty, create a network automatically.
     61       network: ""
     62       # Whether to create networks with IPv6 enabled. Requires the Docker daemon to be set up accordingly.
     63       # Only takes effect if "network" is set to "".
     64       enable_ipv6: false
     65       # Whether to use privileged mode or not when launching task containers (privileged mode is required for Docker-in-Docker).
     66       privileged: false
     67       # And other options to be used when the container is started (eg, --add-host=my.forgejo.url:host-gateway).
     68       options:
     69       # The parent directory of a job's working directory.
     70       # If it's empty, /workspace will be used.
     71       workdir_parent:
     72       # Volumes (including bind mounts) can be mounted to containers. Glob syntax is supported, see https://github.com/gobwas/glob
     73       # You can specify multiple volumes. If the sequence is empty, no volumes can be mounted.
     74       # For example, if you only allow containers to mount the `data` volume and all the json files in `/src`, you should change the config to:
     75       # valid_volumes:
     76       #   - data
     77       #   - /src/*.json
     78       # If you want to allow any volume, please use the following configuration:
     79       # valid_volumes:
     80       #   - '**'
     81       valid_volumes: []
     82       # overrides the docker client host with the specified one.
     83       # If it's empty, act_runner will find an available docker host automatically.
     84       # If it's "-", act_runner will find an available docker host automatically, but the docker host won't be mounted to the job containers and service containers.
     85       # If it's not empty or "-", the specified docker host will be used. An error will be returned if it doesn't work.
     86       docker_host: ""
     87       # Pull docker image(s) even if already present
     88       force_pull: false
     89 
     90     host:
     91       # The parent directory of a job's working directory.
     92       # If it's empty, $HOME/.cache/act/ will be used.
     93       workdir_parent: /data