GitLab Associate CI CD Fundamentals Quiz

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Thames
T
Thames
Community Contributor
Quizzes Created: 11982 | Total Attempts: 187,298
| Attempts: 27 | Questions: 20 | Updated: Aug 16, 2026
Please wait...
Question 1 / 21
🏆 Rank #-- ▾
0 %
0/100
Score 0/100

1. What is the purpose of the 'cache' keyword in GitLab CI/CD?

Explanation

The `cache` keyword preserves selected files or dependencies between CI/CD job runs. Reusing them avoids downloading or rebuilding the same resources each time, helping jobs run faster.

Submit
Please wait...
About This Quiz
GitLab Associate Ci CD Fundamentals Quiz - Quiz

This quiz evaluates your understanding of GitLab CI\/CD fundamentals, covering pipelines, runners, artifacts, and deployment strategies. Designed for college-level learners preparing for GitLab certification, it tests practical knowledge of continuous integration and continuous deployment concepts essential for modern DevOps workflows.

2.

What first name or nickname would you like us to use?

You may optionally provide this to label your report, leaderboard, or certificate.

2. Which GitLab feature allows you to rerun a failed pipeline job?

Explanation

Pipeline retry lets you rerun a failed job within an existing pipeline without starting the entire pipeline over. This is useful when a job fails because of a temporary issue, such as a network or service disruption.

Submit

3. What is the function of the 'artifacts' keyword's 'expire_in' attribute?

Explanation

The `expire_in` attribute defines the retention period for job artifacts. Once that period passes, the artifacts are eligible for automatic deletion, helping manage storage usage.

Submit

4. In GitLab CI/CD, what does 'parallel' do?

Explanation

The `parallel` keyword in GitLab CI/CD runs multiple instances of the same job at the same time. This can speed up pipelines by distributing work across concurrent jobs, often with each instance handling a separate portion of the task.

Submit

5. What is the 'image' keyword used for in GitLab CI/CD?

Explanation

In a GitLab CI/CD configuration, `image` names the container image used to run a job. The image provides the operating system, tools, and dependencies available during that job, such as a particular language runtime or build environment. This setting is useful when the job runs with a compatible container executor.

Submit

6. What is the purpose of the 'before_script' keyword?

Explanation

The `before_script` keyword runs setup commands before the main job script. It is commonly used for tasks such as installing dependencies, configuring the environment, or preparing files needed by the job.

Submit

7. In GitLab CI/CD, what is a 'trigger'?

Explanation

In GitLab CI/CD, a trigger starts a pipeline automatically or on demand in response to events, such as a code push, a schedule, or another pipeline. This lets teams automate workflows without manually launching each pipeline.

Submit

8. What does the 'script' keyword specify in a GitLab CI/CD job?

Explanation

In a GitLab CI/CD job, the `script` keyword lists the shell commands that GitLab Runner executes. These commands perform the job’s tasks, such as building, testing, or deploying an application.

Submit

9. How do you define environment variables securely in GitLab CI/CD?

Explanation

Define sensitive values in GitLab project settings as protected variables. They’re kept outside the repository and can be limited to pipelines running on protected branches or tags. Masking can also prevent values from appearing in job logs, reducing the risk of exposing secrets compared with hardcoding them in `.gitlab-ci.yml` or publishing them in documentation.

Submit

10. What is the primary purpose of a GitLab CI/CD pipeline?

Explanation

A GitLab CI/CD pipeline automates the steps required to build, test, and deploy software. This helps teams verify code changes consistently and deliver updates more efficiently, reducing manual effort and the risk of errors.

Submit

11. In GitLab CI/CD, what is a 'variable'?

Explanation

A GitLab CI/CD variable stores a named value, such as a token, setting, or configuration option, that jobs and scripts can reference during pipeline execution. This helps reuse values and manage environment-specific settings without hard-coding them into scripts.

Submit

12. What does the 'only' keyword control in a GitLab CI/CD job?

Explanation

The `only` keyword specifies the branches or events that trigger a GitLab CI/CD job, allowing it to run only when the defined conditions are met.

Submit

13. What are artifacts in GitLab CI/CD?

Explanation

Artifacts are files or other outputs generated by a CI/CD job and saved by GitLab. They can be downloaded later or passed to subsequent jobs in the pipeline, such as test reports, compiled binaries, or build packages.

Submit

14. What is a GitLab Runner?

Explanation

A GitLab Runner is an application that picks up and runs jobs defined in GitLab CI/CD pipelines. It executes tasks such as building, testing, and deploying code, then reports the results back to GitLab.

Submit

15. Which file defines a GitLab CI/CD pipeline configuration?

Explanation

GitLab looks for a file named `.gitlab-ci.yml` in the repository’s root directory to define the CI/CD pipeline. This YAML file specifies jobs, stages, scripts, and rules that determine how tasks such as building, testing, and deploying the project run. The other filenames are not GitLab’s standard pipeline configuration file.

Submit

16. Which of the following is a valid GitLab Runner executor?

Explanation

GitLab Runner can execute jobs using several environments. The Docker executor runs jobs in containers, the Kubernetes executor schedules them as pods in a cluster, and the Shell executor runs commands directly on the runner host. Since all three are supported executor types, each option is valid.

Submit

17. In GitLab CI/CD, what does a 'stage' represent?

Explanation

A stage groups related CI/CD jobs into a step in the pipeline. Jobs within the same stage can run in parallel, while stages generally run in sequence, allowing later stages to begin after earlier ones complete.

Submit

18. How do you specify that a job should only run on specific runners?

Explanation

Use the `tags` keyword to match a job to runners with the same tags. This lets you direct the job to specific runners configured with the required labels.

Submit

19. Which deployment strategy gradually shifts traffic to a new version?

Explanation

A canary deployment releases a new version to a small subset of users or servers first. If it performs well, traffic is gradually increased; if problems arise, the rollout can be stopped or reversed while most users remain on the stable version.

Submit

20. Which keyword is used to define dependencies between jobs in GitLab CI/CD?

Explanation

In GitLab CI/CD, `needs` specifies which jobs a job depends on. This creates a directed acyclic graph (DAG), allowing jobs to start as soon as their listed dependencies finish instead of waiting for every job in an earlier stage to complete.

Submit
×
Saved
Thank you for your feedback!
View My Results
Cancel
  • All
    All (20)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
What is the purpose of the 'cache' keyword in GitLab CI/CD?
Which GitLab feature allows you to rerun a failed pipeline job?
What is the function of the 'artifacts' keyword's 'expire_in'...
In GitLab CI/CD, what does 'parallel' do?
What is the 'image' keyword used for in GitLab CI/CD?
What is the purpose of the 'before_script' keyword?
In GitLab CI/CD, what is a 'trigger'?
What does the 'script' keyword specify in a GitLab CI/CD job?
How do you define environment variables securely in GitLab CI/CD?
What is the primary purpose of a GitLab CI/CD pipeline?
In GitLab CI/CD, what is a 'variable'?
What does the 'only' keyword control in a GitLab CI/CD job?
What are artifacts in GitLab CI/CD?
What is a GitLab Runner?
Which file defines a GitLab CI/CD pipeline configuration?
Which of the following is a valid GitLab Runner executor?
In GitLab CI/CD, what does a 'stage' represent?
How do you specify that a job should only run on specific runners?
Which deployment strategy gradually shifts traffic to a new version?
Which keyword is used to define dependencies between jobs in GitLab...
play-Mute sad happy unanswered_answer up-hover down-hover success oval cancel Check box square blue
Alert!