The module lifecycle stageExperimental
The module has requirements for installation

The Deckhouse Kubernetes Platform installs CRDs but does not remove them when a module is disabled. If you no longer need the created CRDs, delete them.

AnsibleRun

Scope: Namespaced
Version: v1alpha1

AnsibleRun is the Schema for the ansibleruns API.
  • apiVersion
    string
    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
  • kind
    string
    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
  • metadata
    object
  • spec
    object
    AnsibleRunSpec defines the desired state of AnsibleRun.
    • spec.connection
      object

      Required value

      Connection defines over which transport, with which credentials and through which network the run reaches its hosts.
      • spec.connection.network
        object

        Network the run goes through. Omitted means the main network, where the runner stays in the cluster pod network and reaches virtual machines at their status.ipAddress.

        Naming an additional network of the sdn module states which network the run is executed in. The runner Pod is attached to that network, and the address of a target virtual machine is taken from it as well. The network must have an address pool (spec.ipam.ipAddressPoolRef). Without one neither the machine nor the runner has an address to use.

        Additional networks are available in commercial editions. In the Community Edition a run is executed in the main network, and any other network type is refused.

        • spec.connection.network.name
          string
          Name of the Network or ClusterNetwork. Required for those two types and not allowed for Main, which has no name of its own.

          Minimal length: 1

        • spec.connection.network.type
          string
          Type of the network.

          Default: Main

          Allowed values: Main, Network, ClusterNetwork

      • spec.connection.secretRef
        object

        Required value

        SecretRef references a Kubernetes Secret containing SSH credentials. The Secret must be in the same namespace as the AnsibleRun and contain at least one of (key names follow the built-in kubernetes.io/ssh-auth and kubernetes.io/basic-auth Secret types):

        • ssh-privatekey: SSH private key.
        • password: SSH password. Optional keys:
        • username: SSH username.
        • become-password: Password for privilege escalation.
        • ansible-vault-password: Password for Ansible Vault, the file encryption format of Ansible itself. The name refers to that format, not to a secret store such as HashiCorp Vault or Deckhouse Stronghold.
        • spec.connection.secretRef.name
          string

          Required value

          Name of the Secret.

          Minimal length: 1

      • spec.connection.type
        string
        Type of the transport the run reaches its targets over. SSH is the only one today.

        Default: SSH

        Allowed values: SSH

    • spec.playbook
      object

      Required value

      Playbook defines where the playbook comes from, which part of it runs, and with which values. Options that do not change which tasks run (check mode, diff output, log verbosity) belong to Runner.
      • spec.playbook.configMapRef
        object
        ConfigMap reference to a ConfigMap containing the playbook.
        • spec.playbook.configMapRef.key
          string
          Key is the data key in the ConfigMap containing the playbook. Defaults to “playbook.yaml”.
        • spec.playbook.configMapRef.name
          string

          Required value

          Name is the name of the ConfigMap.
      • spec.playbook.git
        object
        Git checks out the playbook project from a Git repository.
        • spec.playbook.git.path
          string
          Path to the playbook file inside the repository. Defaults to “playbook.yaml”.
        • spec.playbook.git.revision
          string
          Revision is the branch, tag or commit SHA to check out. Defaults to the default branch of the repository.
        • spec.playbook.git.secretRef
          object

          SecretRef references a Kubernetes Secret with the repository credentials (key names follow the built-in kubernetes.io/ssh-auth and kubernetes.io/basic-auth Secret types):

          • For SSH URLs: ssh-privatekey and known_hosts, both required.
          • For HTTP(S) URLs: username and password, where a token is passed as the password, and optionally ca.crt for a self-hosted server with a custom certificate authority.
          • spec.playbook.git.secretRef.name
            string

            Required value

            Name of the Secret.

            Minimal length: 1

        • spec.playbook.git.url
          string

          Required value

          URL of the repository over HTTP(S) or SSH (explicit ssh:// form; the scp-like git@host:path shorthand is not accepted). SSH URLs require SecretRef.

          Pattern: ^(https?|ssh)://.+

      • spec.playbook.inline
        string
        Inline playbook content.

        Maximum length: 65536

      • spec.playbook.skipTags
        array of strings

        SkipTags leave out the tasks marked with these Ansible tags, the way “ansible-playbook –skip-tags” does.

        A tag is any string without whitespace and without a comma. A comma separates tags in the argument, and Ansible strips whitespace itself.

        • spec.playbook.skipTags.Element of the array
          string

          Length: 1..63

          Pattern: ^[^\s,]+$

      • spec.playbook.tags
        array of strings

        Tags run only the tasks marked with these Ansible tags, the way “ansible-playbook –tags” does. Set together with SkipTags, the run is what Tags select minus what SkipTags exclude.

        The tags Ansible reserves work as they do in the command line. “always” runs under any filter until it is named in SkipTags, “never” runs only when named here, and “tagged”, “untagged” and “all” select tasks by whether they carry a tag at all.

        A filter that matches no task is not an error. ansible-playbook succeeds having done nothing, and the run reports it in .status.message.

        • spec.playbook.tags.Element of the array
          string

          Length: 1..63

          Pattern: ^[^\s,]+$

      • spec.playbook.type
        string
        Type specifies the playbook source type.

        Default: Inline

        Allowed values: Inline, ConfigMap, Git

      • spec.playbook.vars
        array of objects

        Vars are the variables this run passes to the playbook, so that one playbook can run with different values. They reach ansible-playbook as –extra-vars, the highest level of Ansible precedence, so they take precedence over the values set by the playbook and its project, and over the host variables of a target.

        A name may appear once. Entries are identified by name, so a server-side apply merges the list by variable rather than replacing it whole.

        • spec.playbook.vars.name
          string
          Name of the variable, as the playbook refers to it. An Ansible identifier: a letter or an underscore, then letters, digits and underscores.

          Length: 1..63

          Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

        • spec.playbook.vars.value
          Value of the variable. Any YAML the playbook expects, such as a string, a number, a list or a mapping.
        • spec.playbook.vars.valueFrom
          object
          ValueFrom takes the value from a key of a Secret or a ConfigMap. Such a value is always a string, because it reaches the runner through the Pod environment, and the environment holds strings. A playbook that needs a list or a mapping parses the string itself with the from_yaml filter.
          • spec.playbook.vars.valueFrom.configMapKeyRef
            object
            ConfigMapKeyRef takes the value from a key of a ConfigMap in the same namespace.
            • spec.playbook.vars.valueFrom.configMapKeyRef.key
              string

              Required value

              The key to select.
            • spec.playbook.vars.valueFrom.configMapKeyRef.name
              string
              Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

              Default: ‘’

            • spec.playbook.vars.valueFrom.configMapKeyRef.optional
              boolean
              Specify whether the ConfigMap or its key must be defined
          • spec.playbook.vars.valueFrom.secretKeyRef
            object
            SecretKeyRef takes the value from a key of a Secret in the same namespace.
            • spec.playbook.vars.valueFrom.secretKeyRef.key
              string

              Required value

              The key of the secret to select from. Must be a valid secret key.
            • spec.playbook.vars.valueFrom.secretKeyRef.name
              string
              Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

              Default: ‘’

            • spec.playbook.vars.valueFrom.secretKeyRef.optional
              boolean
              Specify whether the Secret or its key must be defined
      • spec.playbook.varsFiles
        array of objects

        VarsFiles takes whole sets of variables from YAML documents kept in Secrets and ConfigMaps. This is the manifest form of “-e @vars.yml”, and the place for what a project would keep in group_vars.

        The key holds a mapping of variable names to values, and a value keeps the type it was written with. A list stays a list, and “1.10” stays a string because it was quoted. Use a file rather than a key per variable when the set has structure.

        The kubelet mounts the file into the runner and the controller never reads it, so its contents never reach an object created by the module, and the variable names inside are not checked. A file is trusted the way the playbook is.

        A later entry overrides an earlier one, and everything in Vars overrides all of them.

        • spec.playbook.varsFiles.configMapRef
          object
          ConfigMapRef takes the file from a ConfigMap in the same namespace.
          • spec.playbook.varsFiles.configMapRef.key
            string
            Key is the data key holding the YAML document. Defaults to “vars.yaml”.

            Maximum length: 253

          • spec.playbook.varsFiles.configMapRef.name
            string

            Required value

            Name of the object.

            Length: 1..253

          • spec.playbook.varsFiles.configMapRef.optional
            boolean
            Optional lets the run proceed without these variables when the object or the key is absent. Without it a missing object holds the run in Pending until it appears, and a missing key fails the run.
        • spec.playbook.varsFiles.secretRef
          object
          SecretRef takes the file from a Secret in the same namespace.
          • spec.playbook.varsFiles.secretRef.key
            string
            Key is the data key holding the YAML document. Defaults to “vars.yaml”.

            Maximum length: 253

          • spec.playbook.varsFiles.secretRef.name
            string

            Required value

            Name of the object.

            Length: 1..253

          • spec.playbook.varsFiles.secretRef.optional
            boolean
            Optional lets the run proceed without these variables when the object or the key is absent. Without it a missing object holds the run in Pending until it appears, and a missing key fails the run.
    • spec.runner
      object
      Runner defines how ansible-playbook is executed, namely check mode, diff output and log verbosity. It never changes which tasks the playbook runs.
      • spec.runner.diff
        boolean
        Diff enables ansible-playbook –diff output.
      • spec.runner.dryRun
        boolean
        DryRun runs the playbook in Ansible check mode. The run reports what would change without changing anything on the target hosts. Combine with Diff to see the would-be changes in the run output.
      • spec.runner.verbosity
        integer
        Verbosity controls ansible-playbook log verbosity, where 0..4 maps to none/-v/-vv/-vvv/-vvvv.

        Allowed values: 0 <= X <= 4

    • spec.target
      object

      Required value

      Target defines what to run the playbook against, either virtual machines of the platform or hosts named by address. Exactly one block matching Type is set.
      • spec.target.hosts
        array of objects

        Hosts targets hosts named by address. Required when Type is Hosts.

        Available in commercial editions. The Community Edition runs against virtual machines of the platform, and a run targeting hosts by address is refused.

        • spec.target.hosts.address
          string
          Address of the host: an IP address or a DNS name.

          Length: 1..253

        • spec.target.hosts.groups
          array of strings
          Groups are Ansible groups this host belongs to, in addition to “all”. A group name follows the same rules as a variable name.
          • spec.target.hosts.groups.Element of the array
            string

            Maximum length: 63

            Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

        • spec.target.hosts.vars
          array of objects

          Vars are Ansible host variables for this host, facts about this machine declared exactly the way a run variable is. A variable of the same name in spec.playbook.vars takes precedence over one here, because a fact about a machine is written in advance, while the run happens now.

          The names follow the rules that apply wherever a variable is named in the spec: what the module sets itself, and the variables Ansible fills in itself, are refused. A name may appear once.

          • spec.target.hosts.vars.name
            string
            Name of the variable, as the playbook refers to it. An Ansible identifier: a letter or an underscore, then letters, digits and underscores.

            Length: 1..63

            Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

          • spec.target.hosts.vars.value
            Value of the variable. Any YAML the playbook expects, such as a string, a number, a list or a mapping.
          • spec.target.hosts.vars.valueFrom
            object
            ValueFrom takes the value from a key of a Secret or a ConfigMap. Such a value is always a string, because it reaches the runner through the Pod environment, and the environment holds strings. A playbook that needs a list or a mapping parses the string itself with the from_yaml filter.
            • spec.target.hosts.vars.valueFrom.configMapKeyRef
              object
              ConfigMapKeyRef takes the value from a key of a ConfigMap in the same namespace.
              • spec.target.hosts.vars.valueFrom.configMapKeyRef.key
                string

                Required value

                The key to select.
              • spec.target.hosts.vars.valueFrom.configMapKeyRef.name
                string
                Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                Default: ‘’

              • spec.target.hosts.vars.valueFrom.configMapKeyRef.optional
                boolean
                Specify whether the ConfigMap or its key must be defined
            • spec.target.hosts.vars.valueFrom.secretKeyRef
              object
              SecretKeyRef takes the value from a key of a Secret in the same namespace.
              • spec.target.hosts.vars.valueFrom.secretKeyRef.key
                string

                Required value

                The key of the secret to select from. Must be a valid secret key.
              • spec.target.hosts.vars.valueFrom.secretKeyRef.name
                string
                Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                Default: ‘’

              • spec.target.hosts.vars.valueFrom.secretKeyRef.optional
                boolean
                Specify whether the Secret or its key must be defined
      • spec.target.type
        string

        Required value

        Type selects the target kind.

        Allowed values: VirtualMachines, Hosts

      • spec.target.virtualMachines
        object
        VirtualMachines targets virtual machines. Required when Type is VirtualMachines.
        • spec.target.virtualMachines.names
          array of strings
          Names lists specific VirtualMachine names to target. Mutually exclusive with Selector.
        • spec.target.virtualMachines.selector
          object
          Selector defines which VirtualMachines to target by labels. The selector must not be empty. A run is executed once, so targeting every VirtualMachine in the namespace by accident is not allowed. List explicit labels or use Names instead. Mutually exclusive with Names.
          • spec.target.virtualMachines.selector.matchExpressions
            array of objects
            matchExpressions is a list of label selector requirements. The requirements are ANDed.
            • spec.target.virtualMachines.selector.matchExpressions.key
              string
              key is the label key that the selector applies to.
            • spec.target.virtualMachines.selector.matchExpressions.operator
              string
              operator represents a key’s relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
            • spec.target.virtualMachines.selector.matchExpressions.values
              array of strings
              values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
          • spec.target.virtualMachines.selector.matchLabels
            object
            matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is “key”, the operator is “In”, and the values array contains only “value”. The requirements are ANDed.
  • status
    object
    AnsibleRunStatus defines the observed state of AnsibleRun.
    • status.completionTime
      string
      CompletionTime is the time the run finished.
    • status.conditions
      array of objects
      Conditions represent the latest available observations of the object’s state.
      • status.conditions.lastTransitionTime
        string
        lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
      • status.conditions.message
        string
        message is a human readable message indicating details about the transition. This may be an empty string.

        Maximum length: 32768

      • status.conditions.observedGeneration
        integer
        observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.

        Allowed values: 0 <= X

      • status.conditions.reason
        string
        reason contains a programmatic identifier indicating the reason for the condition’s last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.

        Length: 1..1024

        Pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$

      • status.conditions.status
        string
        status of the condition, one of True, False, Unknown.

        Allowed values: True, False, Unknown

      • status.conditions.type
        string
        type of condition in CamelCase or in foo.example.com/CamelCase.

        Maximum length: 316

        Pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$

    • status.failures
      array of objects
      Failures contains details of failed tasks (max 20).
      • status.failures.host
        string
        Host where the task failed.
      • status.failures.message
        string
        Error message.
      • status.failures.task
        string
        Name of the failed task.
    • status.hosts
      array of objects
      Hosts contains one entry per targeted host. The entry holds the name and the address resolved when the run started, and the per-host playbook statistics filled in when the run finishes.
      • status.hosts.address
        string
        Address of the host resolved when the run started.
      • status.hosts.changed
        integer
        Number of changed tasks.
      • status.hosts.failed
        integer
        Number of failed tasks.
      • status.hosts.ignored
        integer
        Number of tasks that failed under ignore_errors and did not fail the run.
      • status.hosts.name
        string
        Name of the host.
      • status.hosts.ok
        integer
        Number of completed tasks.
      • status.hosts.rescued
        integer
        Number of tasks that failed and were recovered by a rescue block.
      • status.hosts.skipped
        integer
        Number of skipped tasks.
      • status.hosts.unreachable
        integer
        Number of unreachable results reported for this host by its PLAY RECAP line, and a non-zero value means the playbook could not reach the host.
    • status.message
      string
      Message is a human-readable summary of the current state. On failure it also names the runner Pod whose logs hold the full playbook output. It is derived from the run outcome and PodRef, so it is always populated regardless of whether the Ansible output could be parsed.
    • status.phase
      string

      Required value

      Phase represents the current state of the run:

      • Pending: The dependencies and the eligible targets are being checked, and there is no Pod yet.
      • Running: The runner Pod is created, the image is pulled, the init containers run, and then the playbook runs.
      • PlaybookSucceeded: The playbook completed successfully.
      • PlaybookFailed: The playbook ran and reported failed or unreachable hosts.
      • Error: The run never reached the playbook, so there is no Ansible output. The stage it stopped at is named by the reason of the Completed condition.

      Allowed values: Pending, Running, PlaybookSucceeded, PlaybookFailed, Error

    • status.playbookCommit
      string
      PlaybookCommit is the Git commit SHA that was actually checked out and executed. Set only when the playbook source is Git.
    • status.podRef
      object
      PodRef references the Pod running the Ansible playbook.
      • status.podRef.name
        string

        Required value

        Name of the Pod.
      • status.podRef.namespace
        string

        Required value

        Namespace of the Pod.
    • status.skippedHosts
      array of objects
      SkippedHosts contains hosts that were skipped during resolution.
      • status.skippedHosts.busyBy
        string
        BusyBy is the name of the AnsibleRun that is currently using this target. Only set when Reason is TargetBusy.
      • status.skippedHosts.name
        string
        Name of the host.
      • status.skippedHosts.phase
        string
        Phase of the target at the time of resolution.
      • status.skippedHosts.reason
        string
        Reason for skipping.

        Allowed values: NoAddress, NetworkNotAttached, NoAddressInNetwork, TargetNotReady, TargetNotRunning, TargetNotFound, TargetBusy

    • status.startTime
      string
      StartTime is the time the run started.
    • status.summary
      object
      Summary contains aggregated statistics across all hosts.
      • status.summary.failed
        integer

        Required value

        Number of failed hosts.
      • status.summary.skipped
        integer

        Required value

        Number of skipped hosts.
      • status.summary.successful
        integer

        Required value

        Number of successful hosts.
      • status.summary.total
        integer

        Required value

        Total number of hosts targeted by the playbook run (skipped hosts are counted separately in Skipped).
      • status.summary.unreachable
        integer

        Required value

        Number of unreachable hosts.

AnsibleRunSchedule

Scope: Namespaced
Version: v1alpha1

AnsibleRunSchedule creates AnsibleRuns on a cron schedule, the same way a CronJob creates Jobs.
  • apiVersion
    string
    APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
  • kind
    string
    Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
  • metadata
    object
  • spec
    object
    AnsibleRunScheduleSpec defines the desired state of AnsibleRunSchedule.
    • spec.concurrencyPolicy
      string
      ConcurrencyPolicy describes what to do when the previous run is still active at the next tick: skip the tick (Forbid, default), run anyway (Allow) or delete the active run and start a new one (Replace).

      Default: Forbid

      Allowed values: Forbid, Allow, Replace

    • spec.failedRunsHistoryLimit
      integer
      FailedRunsHistoryLimit is how many failed runs to keep.

      Default: 1

      Allowed values: 0 <= X

    • spec.schedule
      string

      Required value

      Schedule in standard cron format (five fields).

      Minimal length: 1

    • spec.startingDeadlineSeconds
      integer
      StartingDeadlineSeconds bounds how late a missed run may still start. A tick missed by more than this is skipped entirely; missed runs are never replayed.

      Allowed values: 1 <= X

    • spec.successfulRunsHistoryLimit
      integer
      SuccessfulRunsHistoryLimit is how many succeeded runs to keep.

      Default: 3

      Allowed values: 0 <= X

    • spec.suspend
      boolean
      Suspend stops scheduling new runs; already running ones are untouched.
    • spec.template
      object

      Required value

      Template of the AnsibleRun created on every scheduled run.
      • spec.template.metadata
        object
        Metadata applied to the created AnsibleRuns.
        • spec.template.metadata.annotations
          object
          Annotations to set on the created AnsibleRuns.
        • spec.template.metadata.labels
          object
          Labels to set on the created AnsibleRuns.
      • spec.template.spec
        object

        Required value

        Spec of the created AnsibleRuns.
        • spec.template.spec.connection
          object

          Required value

          Connection defines over which transport, with which credentials and through which network the run reaches its hosts.
          • spec.template.spec.connection.network
            object

            Network the run goes through. Omitted means the main network, where the runner stays in the cluster pod network and reaches virtual machines at their status.ipAddress.

            Naming an additional network of the sdn module states which network the run is executed in. The runner Pod is attached to that network, and the address of a target virtual machine is taken from it as well. The network must have an address pool (spec.ipam.ipAddressPoolRef). Without one neither the machine nor the runner has an address to use.

            Additional networks are available in commercial editions. In the Community Edition a run is executed in the main network, and any other network type is refused.

            • spec.template.spec.connection.network.name
              string
              Name of the Network or ClusterNetwork. Required for those two types and not allowed for Main, which has no name of its own.

              Minimal length: 1

            • spec.template.spec.connection.network.type
              string
              Type of the network.

              Default: Main

              Allowed values: Main, Network, ClusterNetwork

          • spec.template.spec.connection.secretRef
            object

            Required value

            SecretRef references a Kubernetes Secret containing SSH credentials. The Secret must be in the same namespace as the AnsibleRun and contain at least one of (key names follow the built-in kubernetes.io/ssh-auth and kubernetes.io/basic-auth Secret types):

            • ssh-privatekey: SSH private key.
            • password: SSH password. Optional keys:
            • username: SSH username.
            • become-password: Password for privilege escalation.
            • ansible-vault-password: Password for Ansible Vault, the file encryption format of Ansible itself. The name refers to that format, not to a secret store such as HashiCorp Vault or Deckhouse Stronghold.
            • spec.template.spec.connection.secretRef.name
              string

              Required value

              Name of the Secret.

              Minimal length: 1

          • spec.template.spec.connection.type
            string
            Type of the transport the run reaches its targets over. SSH is the only one today.

            Default: SSH

            Allowed values: SSH

        • spec.template.spec.playbook
          object

          Required value

          Playbook defines where the playbook comes from, which part of it runs, and with which values. Options that do not change which tasks run (check mode, diff output, log verbosity) belong to Runner.
          • spec.template.spec.playbook.configMapRef
            object
            ConfigMap reference to a ConfigMap containing the playbook.
            • spec.template.spec.playbook.configMapRef.key
              string
              Key is the data key in the ConfigMap containing the playbook. Defaults to “playbook.yaml”.
            • spec.template.spec.playbook.configMapRef.name
              string

              Required value

              Name is the name of the ConfigMap.
          • spec.template.spec.playbook.git
            object
            Git checks out the playbook project from a Git repository.
            • spec.template.spec.playbook.git.path
              string
              Path to the playbook file inside the repository. Defaults to “playbook.yaml”.
            • spec.template.spec.playbook.git.revision
              string
              Revision is the branch, tag or commit SHA to check out. Defaults to the default branch of the repository.
            • spec.template.spec.playbook.git.secretRef
              object

              SecretRef references a Kubernetes Secret with the repository credentials (key names follow the built-in kubernetes.io/ssh-auth and kubernetes.io/basic-auth Secret types):

              • For SSH URLs: ssh-privatekey and known_hosts, both required.
              • For HTTP(S) URLs: username and password, where a token is passed as the password, and optionally ca.crt for a self-hosted server with a custom certificate authority.
              • spec.template.spec.playbook.git.secretRef.name
                string

                Required value

                Name of the Secret.

                Minimal length: 1

            • spec.template.spec.playbook.git.url
              string

              Required value

              URL of the repository over HTTP(S) or SSH (explicit ssh:// form; the scp-like git@host:path shorthand is not accepted). SSH URLs require SecretRef.

              Pattern: ^(https?|ssh)://.+

          • spec.template.spec.playbook.inline
            string
            Inline playbook content.

            Maximum length: 65536

          • spec.template.spec.playbook.skipTags
            array of strings

            SkipTags leave out the tasks marked with these Ansible tags, the way “ansible-playbook –skip-tags” does.

            A tag is any string without whitespace and without a comma. A comma separates tags in the argument, and Ansible strips whitespace itself.

            • spec.template.spec.playbook.skipTags.Element of the array
              string

              Length: 1..63

              Pattern: ^[^\s,]+$

          • spec.template.spec.playbook.tags
            array of strings

            Tags run only the tasks marked with these Ansible tags, the way “ansible-playbook –tags” does. Set together with SkipTags, the run is what Tags select minus what SkipTags exclude.

            The tags Ansible reserves work as they do in the command line. “always” runs under any filter until it is named in SkipTags, “never” runs only when named here, and “tagged”, “untagged” and “all” select tasks by whether they carry a tag at all.

            A filter that matches no task is not an error. ansible-playbook succeeds having done nothing, and the run reports it in .status.message.

            • spec.template.spec.playbook.tags.Element of the array
              string

              Length: 1..63

              Pattern: ^[^\s,]+$

          • spec.template.spec.playbook.type
            string
            Type specifies the playbook source type.

            Default: Inline

            Allowed values: Inline, ConfigMap, Git

          • spec.template.spec.playbook.vars
            array of objects

            Vars are the variables this run passes to the playbook, so that one playbook can run with different values. They reach ansible-playbook as –extra-vars, the highest level of Ansible precedence, so they take precedence over the values set by the playbook and its project, and over the host variables of a target.

            A name may appear once. Entries are identified by name, so a server-side apply merges the list by variable rather than replacing it whole.

            • spec.template.spec.playbook.vars.name
              string
              Name of the variable, as the playbook refers to it. An Ansible identifier: a letter or an underscore, then letters, digits and underscores.

              Length: 1..63

              Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

            • spec.template.spec.playbook.vars.value
              Value of the variable. Any YAML the playbook expects, such as a string, a number, a list or a mapping.
            • spec.template.spec.playbook.vars.valueFrom
              object
              ValueFrom takes the value from a key of a Secret or a ConfigMap. Such a value is always a string, because it reaches the runner through the Pod environment, and the environment holds strings. A playbook that needs a list or a mapping parses the string itself with the from_yaml filter.
              • spec.template.spec.playbook.vars.valueFrom.configMapKeyRef
                object
                ConfigMapKeyRef takes the value from a key of a ConfigMap in the same namespace.
                • spec.template.spec.playbook.vars.valueFrom.configMapKeyRef.key
                  string

                  Required value

                  The key to select.
                • spec.template.spec.playbook.vars.valueFrom.configMapKeyRef.name
                  string
                  Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                  Default: ‘’

                • spec.template.spec.playbook.vars.valueFrom.configMapKeyRef.optional
                  boolean
                  Specify whether the ConfigMap or its key must be defined
              • spec.template.spec.playbook.vars.valueFrom.secretKeyRef
                object
                SecretKeyRef takes the value from a key of a Secret in the same namespace.
                • spec.template.spec.playbook.vars.valueFrom.secretKeyRef.key
                  string

                  Required value

                  The key of the secret to select from. Must be a valid secret key.
                • spec.template.spec.playbook.vars.valueFrom.secretKeyRef.name
                  string
                  Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                  Default: ‘’

                • spec.template.spec.playbook.vars.valueFrom.secretKeyRef.optional
                  boolean
                  Specify whether the Secret or its key must be defined
          • spec.template.spec.playbook.varsFiles
            array of objects

            VarsFiles takes whole sets of variables from YAML documents kept in Secrets and ConfigMaps. This is the manifest form of “-e @vars.yml”, and the place for what a project would keep in group_vars.

            The key holds a mapping of variable names to values, and a value keeps the type it was written with. A list stays a list, and “1.10” stays a string because it was quoted. Use a file rather than a key per variable when the set has structure.

            The kubelet mounts the file into the runner and the controller never reads it, so its contents never reach an object created by the module, and the variable names inside are not checked. A file is trusted the way the playbook is.

            A later entry overrides an earlier one, and everything in Vars overrides all of them.

            • spec.template.spec.playbook.varsFiles.configMapRef
              object
              ConfigMapRef takes the file from a ConfigMap in the same namespace.
              • spec.template.spec.playbook.varsFiles.configMapRef.key
                string
                Key is the data key holding the YAML document. Defaults to “vars.yaml”.

                Maximum length: 253

              • spec.template.spec.playbook.varsFiles.configMapRef.name
                string

                Required value

                Name of the object.

                Length: 1..253

              • spec.template.spec.playbook.varsFiles.configMapRef.optional
                boolean
                Optional lets the run proceed without these variables when the object or the key is absent. Without it a missing object holds the run in Pending until it appears, and a missing key fails the run.
            • spec.template.spec.playbook.varsFiles.secretRef
              object
              SecretRef takes the file from a Secret in the same namespace.
              • spec.template.spec.playbook.varsFiles.secretRef.key
                string
                Key is the data key holding the YAML document. Defaults to “vars.yaml”.

                Maximum length: 253

              • spec.template.spec.playbook.varsFiles.secretRef.name
                string

                Required value

                Name of the object.

                Length: 1..253

              • spec.template.spec.playbook.varsFiles.secretRef.optional
                boolean
                Optional lets the run proceed without these variables when the object or the key is absent. Without it a missing object holds the run in Pending until it appears, and a missing key fails the run.
        • spec.template.spec.runner
          object
          Runner defines how ansible-playbook is executed, namely check mode, diff output and log verbosity. It never changes which tasks the playbook runs.
          • spec.template.spec.runner.diff
            boolean
            Diff enables ansible-playbook –diff output.
          • spec.template.spec.runner.dryRun
            boolean
            DryRun runs the playbook in Ansible check mode. The run reports what would change without changing anything on the target hosts. Combine with Diff to see the would-be changes in the run output.
          • spec.template.spec.runner.verbosity
            integer
            Verbosity controls ansible-playbook log verbosity, where 0..4 maps to none/-v/-vv/-vvv/-vvvv.

            Allowed values: 0 <= X <= 4

        • spec.template.spec.target
          object

          Required value

          Target defines what to run the playbook against, either virtual machines of the platform or hosts named by address. Exactly one block matching Type is set.
          • spec.template.spec.target.hosts
            array of objects

            Hosts targets hosts named by address. Required when Type is Hosts.

            Available in commercial editions. The Community Edition runs against virtual machines of the platform, and a run targeting hosts by address is refused.

            • spec.template.spec.target.hosts.address
              string
              Address of the host: an IP address or a DNS name.

              Length: 1..253

            • spec.template.spec.target.hosts.groups
              array of strings
              Groups are Ansible groups this host belongs to, in addition to “all”. A group name follows the same rules as a variable name.
              • spec.template.spec.target.hosts.groups.Element of the array
                string

                Maximum length: 63

                Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

            • spec.template.spec.target.hosts.vars
              array of objects

              Vars are Ansible host variables for this host, facts about this machine declared exactly the way a run variable is. A variable of the same name in spec.playbook.vars takes precedence over one here, because a fact about a machine is written in advance, while the run happens now.

              The names follow the rules that apply wherever a variable is named in the spec: what the module sets itself, and the variables Ansible fills in itself, are refused. A name may appear once.

              • spec.template.spec.target.hosts.vars.name
                string
                Name of the variable, as the playbook refers to it. An Ansible identifier: a letter or an underscore, then letters, digits and underscores.

                Length: 1..63

                Pattern: ^[A-Za-z_][A-Za-z0-9_]*$

              • spec.template.spec.target.hosts.vars.value
                Value of the variable. Any YAML the playbook expects, such as a string, a number, a list or a mapping.
              • spec.template.spec.target.hosts.vars.valueFrom
                object
                ValueFrom takes the value from a key of a Secret or a ConfigMap. Such a value is always a string, because it reaches the runner through the Pod environment, and the environment holds strings. A playbook that needs a list or a mapping parses the string itself with the from_yaml filter.
                • spec.template.spec.target.hosts.vars.valueFrom.configMapKeyRef
                  object
                  ConfigMapKeyRef takes the value from a key of a ConfigMap in the same namespace.
                  • spec.template.spec.target.hosts.vars.valueFrom.configMapKeyRef.key
                    string

                    Required value

                    The key to select.
                  • spec.template.spec.target.hosts.vars.valueFrom.configMapKeyRef.name
                    string
                    Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                    Default: ‘’

                  • spec.template.spec.target.hosts.vars.valueFrom.configMapKeyRef.optional
                    boolean
                    Specify whether the ConfigMap or its key must be defined
                • spec.template.spec.target.hosts.vars.valueFrom.secretKeyRef
                  object
                  SecretKeyRef takes the value from a key of a Secret in the same namespace.
                  • spec.template.spec.target.hosts.vars.valueFrom.secretKeyRef.key
                    string

                    Required value

                    The key of the secret to select from. Must be a valid secret key.
                  • spec.template.spec.target.hosts.vars.valueFrom.secretKeyRef.name
                    string
                    Name of the referent. This field is effectively required, but due to backwards compatibility is allowed to be empty. Instances of this type with an empty value here are almost certainly wrong. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names

                    Default: ‘’

                  • spec.template.spec.target.hosts.vars.valueFrom.secretKeyRef.optional
                    boolean
                    Specify whether the Secret or its key must be defined
          • spec.template.spec.target.type
            string

            Required value

            Type selects the target kind.

            Allowed values: VirtualMachines, Hosts

          • spec.template.spec.target.virtualMachines
            object
            VirtualMachines targets virtual machines. Required when Type is VirtualMachines.
            • spec.template.spec.target.virtualMachines.names
              array of strings
              Names lists specific VirtualMachine names to target. Mutually exclusive with Selector.
            • spec.template.spec.target.virtualMachines.selector
              object
              Selector defines which VirtualMachines to target by labels. The selector must not be empty. A run is executed once, so targeting every VirtualMachine in the namespace by accident is not allowed. List explicit labels or use Names instead. Mutually exclusive with Names.
              • spec.template.spec.target.virtualMachines.selector.matchExpressions
                array of objects
                matchExpressions is a list of label selector requirements. The requirements are ANDed.
                • spec.template.spec.target.virtualMachines.selector.matchExpressions.key
                  string
                  key is the label key that the selector applies to.
                • spec.template.spec.target.virtualMachines.selector.matchExpressions.operator
                  string
                  operator represents a key’s relationship to a set of values. Valid operators are In, NotIn, Exists and DoesNotExist.
                • spec.template.spec.target.virtualMachines.selector.matchExpressions.values
                  array of strings
                  values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.
              • spec.template.spec.target.virtualMachines.selector.matchLabels
                object
                matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is “key”, the operator is “In”, and the values array contains only “value”. The requirements are ANDed.
    • spec.timeZone
      string
      TimeZone name for the schedule (IANA, for example “Europe/Moscow”). Defaults to UTC.
  • status
    object
    AnsibleRunScheduleStatus defines the observed state of AnsibleRunSchedule.
    • status.active
      array of strings
      Active lists the names of currently running AnsibleRuns created by this schedule.
    • status.conditions
      array of objects
      Conditions represent the latest available observations of the object’s state.
      • status.conditions.lastTransitionTime
        string
        lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable.
      • status.conditions.message
        string
        message is a human readable message indicating details about the transition. This may be an empty string.

        Maximum length: 32768

      • status.conditions.observedGeneration
        integer
        observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance.

        Allowed values: 0 <= X

      • status.conditions.reason
        string
        reason contains a programmatic identifier indicating the reason for the condition’s last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty.

        Length: 1..1024

        Pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$

      • status.conditions.status
        string
        status of the condition, one of True, False, Unknown.

        Allowed values: True, False, Unknown

      • status.conditions.type
        string
        type of condition in CamelCase or in foo.example.com/CamelCase.

        Maximum length: 316

        Pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$

    • status.lastScheduleTime
      string
      LastScheduleTime is when a run was last created.
    • status.lastSuccessfulTime
      string
      LastSuccessfulTime is when a run last finished successfully.