Skip to content

Woodpecker agents

services.woodpecker-agents.agents

woodpecker-agents configurations Type: attribute set of (submodule)

Default

{ }

Example

`#!nix { podman = { environment = { WOODPECKER_SERVER = "localhost:9000"; WOODPECKER_BACKEND = "docker"; DOCKER_HOST = "unix:///run/podman/podman.sock"; };

extraGroups = [ "podman" ];

environmentFile = [ "/run/secrets/woodpecker/agent-secret.txt" ];

};

exec = { environment = { WOODPECKER_SERVER = "localhost:9000"; WOODPECKER_BACKEND = "local"; };

environmentFile = [ "/run/secrets/woodpecker/agent-secret.txt" ];

path = [
  # Needed to clone repos
  git
  git-lfs
  woodpecker-plugin-git
  # Used by the runner as the default shell
  bash
  # Most likely to be used in pipeline definitions
  coreutils
];

}; } `

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.enable

Whether to enable this Woodpecker-Agent. Agents execute tasks generated by a Server, every install will need one server and at least one agent. Type: boolean

Default

false

Example

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.environment

woodpecker-agent config environment variables, for other options read the documentation Type: attribute set of string

Default

{ }

Example

{WOODPECKER_SERVER = "localhost:9000";WOODPECKER_BACKEND = "docker";DOCKER_HOST = "unix:///run/podman/podman.sock";}

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.environmentFile

File to load environment variables from. This is helpful for specifying secrets. Example content of environmentFile:

WOODPECKER_AGENT_SECRET=your-shared-secret-goes-here

Type: list of path

Default

[ ]

Example

["/var/secrets/woodpecker-agent.env"]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.extraGroups

Additional groups for the systemd service.

Type: list of string

Default

[ ]

Example

["podman"]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.package

The woodpecker-agent package to use. Type: package

Default

pkgs.woodpecker-agent

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix

services.woodpecker-agents.agents.<name>.path

Additional packages that should be added to the agent's PATH. Mostly useful for the local backend.

Type: list of package

Default

[ ]

Example

[""]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/continuous-integration/woodpecker/agents.nix