{% extends 'generic/object.html' %} {% load helpers %} {% block extra_controls %}
{% endblock %} {% block content %}| Repository | {{ object.url }} |
|---|---|
| Branch | {{ object.branch }} |
| Enabled | {% checkmark object.enabled %} |
| Access | {% if object.token_encrypted %}HTTPS token for {{ object.username|default:"git" }}{% elif object.ssh_key_encrypted %}SSH deploy key{% else %}none (local or anonymous){% endif %} |
| Strict mode | {% checkmark object.strict %}{% if object.strict %} nothing is deployed while the repository is unreachable{% endif %} |
| Email addresses | {% checkmark object.include_email %}{% if not object.include_email %} authors as <username>@netbox{% endif %} |
| Last test | {% if object.last_result %}{% if object.last_result.ok %}ok{% else %}failed{% endif %} {{ object.last_result.detail }}{% else %}—{% endif %} |
One repository per NetBox installation, one folder per Checkmk instance (instances/<instance>/hosts/<host>.yaml, tag and contact groups, revisions/<no>.yaml). Every revision becomes a commit; the author is the NetBox user who deployed. Nothing is pushed with --force, so a protected branch works. No secrets are written.
write_repository; user name: any non-empty value, e.g. oauth2. Commit link: https://gitlab.example.com/group/repo/-/commit/{sha}x-access-token. Commit link: https://github.com/org/repo/commit/{sha}write:repository; user name: your login. Commit link: https://gitea.example.com/org/repo/commit/{sha}x-token-auth.git@host:path/repo.git.The rollback never depends on Git: it always runs from the revisions in the NetBox database.
| {{ r|linkify }} | {% if link %}{{ r.git_commit|truncatechars:12 }}{% else %}{{ r.git_commit|truncatechars:12 }}{% endif %} |
| nothing pushed yet | |
| {{ r|linkify }} | not pushed yet: {{ r.git_error }} |