GitLab Quick Start Guide

Book description

Port projects over from GitHub and convert SVN projects to GitLab hosted git projects

Key Features

  • Effective guide for GitLab migration from GitHub and SVN
  • Learn to implement DevOps with GitLab 11
  • Manage projects with issue boards and time tracking

Book Description

Gitlab is an open source repository management and version control toolkit with an enterprise offering. This book is the ideal guide to GitLab as a version control system (VCS), issue management tool, and a continuous integration platform.

The book starts with an introduction to GitLab, a walkthrough of its features, and explores concepts such as version control systems, continuous integration, and continuous deployment. It then takes you through the process of downloading and installing a local copy of the on-premise version of GitLab in Ubuntu and/or CentOS.

You will look at some common work?ows associated with GitLab work?ow and learn about project management in GitLab. You will see tools and techniques for migrating your code base from various version control systems such as GitHub and SVN to GitLab.

By the end of the book, you will be using Gitlab for repository management, and be able to migrate projects from other VCSs to GitLab.

What you will learn

  • Set up CI and test builds for your projects
  • Understand the benefits and limitations of GitLab work?ow
  • Migrate from other common VCS platforms to Gitlab
  • Create, review, and merge code changes
  • Learn to branch local code and create a new branch in GitLab
  • Configure sequential stages and simultaneous stages for CI/CD
  • Access Mattermost for on-premise GitLab
  • Discover the issue tracking features of GitLab

Who this book is for

The book is intended for the developers, SREs, and DevOps professionals who are looking for techniques to port their codebase to GitLab from GitHub or are looking to work with GitLab as their version control system of choice. If you've used other VCSs before, that will help with this book.

Table of contents

  1. Title page
  2. Copyright and Credits
    1. GitLab Quick Start Guide
  3. Dedication
  4. About Packt
    1. Why subscribe?
    2. Packt.com
  5. Contributors
    1. About the author
    2. About the reviewer
    3. Packt is searching for authors like you
  6. Preface
    1. Who this book is for
    2. What this book covers
    3. To get the most out of this book
      1. Download the example code files
      2. Download the color images
      3. Conventions used
    4. Get in touch
      1. Reviews
  7. Introducing GitLab
    1. Version control systems and Git
      1. GitLab and Git
    2. Features
      1. Self-managed versus Software as a Service (SaaS)
      2. Free versus paid
    3. Summary
  8. Setting Up GitLab
    1. Requirements
      1. Hardware
      2. Operating system
      3. Languages and applications
    2. Omnibus on Ubuntu/Debian
    3. Omnibus on CentOS/RHEL/Scientific Linux/Oracle Linux
    4. Manual installation
      1. Initial packages
      2. Languages, frameworks, and Git
      3. Databases
      4. GitLab
      5. Installing nginx
    5. Setting up HTTPS
      1. Let's Encrypt
      2. HTTPS certificates
    6. Creating accounts on GitLab
    7. Summary
  9. GitLab Flow
    1. Using Git
      1. Git commands
    2. GitFlow
      1. Master
      2. Develop
      3. Features
      4. Releases
      5. Hotfixes
    3. GitLab Flow
      1. Production branch
      2. Staging branch
      3. Release branch
      4. Differences from GitHub flow
    4. Summary
  10. Issues to Merge Requests
    1. Creating projects
      1. Creating an SSH key
      2. Committing to a project
        1. Blank slate
        2. Existing folder
        3. Existing git repository
      3. Starting our example project
      4. Adding other project members
    2. Issues
      1. Creating an issue
      2. Comments
      3. Issue board
      4. Labels
      5. Milestones
    3. Merge requests
      1. Example project continued
      2. Creating a merge request
      3. Code review with merge requests
    4. Summary
  11. Continuous Integration and Continuous Deployment
    1. How to install GitLab Runner
      1. Ubuntu
      2. CentOS
      3. Binaries
      4. How to register Runners
        1. Admin panel
        2. Project settings
        3. Registering the CLI
    2. Adding to our example project
    3. Breaking down .gitlab-ci.yml
      1. Jobs
        1. The script parameter
        2. The before_script and after_script parameters
        3. The stage parameter
        4. The image parameter
        5. The services parameter
        6. The only and except parameters
        7. The tags parameter
        8. The allow_failure parameter
        9. The when parameter
        10. The environment parameter
        11. The cache parameter
          1. cache – paths
          2. cache – key
          3. cache – untracked
          4. cache – policy
        12. The artifacts parameter
          1. artifacts – paths
          2. artifacts – name
          3. artifacts – untracked
          4. artifacts – when
          5. artifacts – expire_in
        13. The variables parameter
        14. Other parameters
    4. Adding .gitlab-ci.yml to our example project
    5. Deconstructing an advanced .gitlab-ci.yml file
    6. GitLab CI/CD web UI
    7. Summary
  12. Porting from GitHub or Subversion (SVN)
    1. Changing code-hosting platform
      1. GitHub
        1. GitLab.com or GitHub integration enabled
        2. Personal access token
        3. Importing repositories
      2. BitBucket
      3. Project URL
      4. Clone and push
    2. Moving from another version control system
      1. Subversion
      2. Mercurial
    3. Summary
  13. Advanced and Paid Features
    1. Snippets
    2. Wiki
    3. Groups
      1. Moving projects
      2. Epics
    4. Mattermost
    5. Self-hosted administration
    6. Issue tracking
      1. Related issues
      2. Issue weights
      3. Burndown charts
    7. Merge request approvals
    8. Summary
  14. Introduction To Markdown
    1. Markdown overview
      1. Headings
      2. Emphasis
      3. Lists
      4. Links and images
      5. Code
  15. Other Books You May Enjoy
    1. Leave a review - let other readers know what you think

Product information

  • Title: GitLab Quick Start Guide
  • Author(s): Adam O'Grady
  • Release date: November 2018
  • Publisher(s): Packt Publishing
  • ISBN: 9781789534344