Skip to content
Snippets Groups Projects

Ansible GitLab Runner

  • Clone with SSH
  • Clone with HTTPS
  • Embed
  • Share
    The snippet can be accessed without any authentication.
    Authored by Jonah
    Edited
    snippetfile1.txt 503 B
    - name: Import the gitlab-runner runner pgp key
      get_url:
        url: https://packages.gitlab.com/gpg.key
        dest: /etc/apt/trusted.gpg.d/gitlab.asc
    
    - name: Add gitlab-runner repository
      apt_repository:
        repo: deb https://packages.gitlab.com/runner/gitlab-runner/debian/ bookworm main
        state: present
    
    - name: Install gitlab-runner
      apt:
        name:
          - gitlab-runner
    
    - name: Enable gitlab-runner
      systemd:
        name: gitlab-runner
        enabled: true
        masked: false
        daemon_reload: true
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment