Skip to content

netorca_pack_pipeline - Mark a NetOrca Pack pipeline as applied

Part of the netautomate.netorca collection (version 2.0.0). Added in version 2.0.0.

Synopsis

  • Set the applied flag of a pack pipeline - the executor's acknowledgement that the run's output has been deployed to the infrastructure.
  • applied is the only pipeline field the platform lets clients write; everything else on a pipeline is produced by the pack framework itself. Flipping it closes the executor loop - applied=false, state=OK pipelines are the executor's work queue (netautomate.netorca.netorca_pack_pipeline_info), and marking them applied takes them out of it.
  • The module fetches the pipeline first and only writes on difference, so it is idempotent.
  • The pack executor endpoints are not covered by the netorca-sdk resource layer yet, so this module speaks to external/{context}/pack/pipelines directly.

Requirements

The below requirements are needed on the host that executes this module.

  • netorca-sdk >= 1.0.9, < 2.0.0

Parameters

Parameter Comments
applied
bool
required
The desired value of the applied flag.
id
int
required
ID of the pipeline.

Common parameters

Connection and query parameters shared by every module in the collection. See Authentication for the environment-variable pattern.

Parameter Comments
context
str
Point of view for the request. The same query returns different data depending on which side of the service relationship your team is on.
serviceowner operates on the services your team offers - the requests made against them, their service items and deployed items. This is the side that validates, approves, deploys and completes changes.
consumer operates on what your team consumes - the service items your applications declared and the change instances tracking your own requests.
If not set, the value of the NETORCA_CONTEXT environment variable is used.
Choices: serviceowner, consumer
Default: serviceowner
api_url
str
required
Base URL of the NetOrca API, for example https://api.example.netorca.io.
The URL is normalised to end in a single /v1, so passing it with or without the suffix both work.
If not set, the value of the NETORCA_API_URL environment variable is used.
api_key
str
required
API key of your NetOrca team. The NetOrca API supports API-key authentication only - there is no username/password mode.
Treat the key like a password - supply it via the NETORCA_API_KEY environment variable (for example from a CI/CD secret) or from Ansible Vault, never as a literal in a playbook.
If not set, the value of the NETORCA_API_KEY environment variable is used.
validate_certs
bool
Whether to validate TLS certificates when talking to the API.
Only disable this for lab instances with self-signed certificates.
If not set, the value of the NETORCA_VALIDATE_CERTS environment variable is used.
Default: true

Attributes

Attribute Support Description
check_mode full The write is predicted from the fetched pipeline without patching.
diff_mode full Returns before/after of the applied flag.

Notes

  • All modules talk to the NetOrca REST API and are typically executed on the controller (hosts=localhost with gather_facts=false, or delegate_to=localhost).
  • Module parameters take precedence over their NETORCA_* environment variable fallbacks.

Examples

- name: Acknowledge a deployed run
  netautomate.netorca.netorca_pack_pipeline:
    id: 2935
    applied: true

- name: Put a run back into the executor queue
  netautomate.netorca.netorca_pack_pipeline:
    id: 2935
    applied: false

Return values

msg

Human-readable summary of what happened.

  • Returned: always
  • Type: str
  • Sample:
"marked applied"

pack_pipeline

The pipeline after the operation (or the projected result in check mode).

  • Returned: always
  • Type: dict
  • Sample:
{
  "applied": true,
  "id": 2935,
  "state": "OK",
  "version": 4
}

See also

Authors

  • NetAutomate (@netautomate)