nerdexam
CompTIA

XK0-005 · Question #756

A DevOps engineer wants to work on a snapshot of the infrastructure as code configuration. Which of the following commands should the engineer use to accomplish this task?

The correct answer is D. git tag <feature>. A git tag creates a named, immutable reference (snapshot) pointing to a specific commit in the repository's history. Unlike branches, tags do not move as new commits are added, making them ideal for marking a fixed point in time - such as a known-good infrastructure…

Scripting, Containers, and Automation

Question

A DevOps engineer wants to work on a snapshot of the infrastructure as code configuration. Which of the following commands should the engineer use to accomplish this task?

Options

  • Agit pull <feature>
  • Bgit push <feature>
  • Cgit branch <feature>
  • Dgit tag <feature>

How the community answered

(38 responses)
  • A
    3% (1)
  • B
    5% (2)
  • C
    3% (1)
  • D
    89% (34)

Explanation

A git tag creates a named, immutable reference (snapshot) pointing to a specific commit in the repository's history. Unlike branches, tags do not move as new commits are added, making them ideal for marking a fixed point in time - such as a known-good infrastructure configuration. 'git branch' creates a movable pointer to commits, 'git pull' fetches and merges remote changes, and 'git push' uploads local commits to a remote - none of which produce a static snapshot.

Topics

#Git#Version Control#Infrastructure as Code#DevOps Tools

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice