liveBook · Manning

What you will learn in GitHub Actions in Action: Continuous integration and delivery for DevOps

Continuous integration and delivery for DevOps

by Michael Kaufmann, Rob Bos Marcel de Vries

Chapter by chapter

Chapter 1: Introduction to GitHub Actions

1.1 An introduction to the GitHub universe · 1.2 What are GitHub Actions and workflows? · 1.3 GitHub Actions: More than CI/CD pipelines · 1.4 Hosting and pricing for GitHub and GitHub Actions · 1.4.1 GitHub Enterprise Cloud · 1.4.2 GitHub Enterprise Server · 1.4.3 GitHub pricing · 1.4.4 GitHub Actions pricing · 1.5 Conclusion · 1.6 Summary

What you learn in chapter 1 →

Chapter 2: Hands-on: My first Actions workflow

2.1 Creating a new workflow · 2.2 Using the workflow editor · 2.3 Using actions from the marketplace · 2.4 Running the workflow · 2.5 Conclusion · 2.6 Summary

What you learn in chapter 2 →

Chapter 3: Workflows

3.1 YAML · 3.1.1 YAML basics · 3.1.2 Data types · 3.2 The workflow syntax · 3.3 Events and triggers · 3.3.1 Webhook triggers · 3.3.2 Scheduled triggers · 3.3.3 Manual triggers · 3.4 Workflow jobs and steps · 3.4.1 Workflow jobs · 3.4.2 Workflow steps · 3.4.3 Using GitHub actions · 3.4.4 The matrix strategy · 3.5 Expressions and contexts · 3.6 Workflow commands · 3.6.1 Writing a debug message · 3.6.2 Creating error or warning messages · 3.6.3 Passing an output to subsequent steps and jobs · 3.6.4 Environment files · 3.6.5 Job summaries · 3.7 Secrets and variables · 3.8 Workflow permissions · 3.9 Authoring and debugging workflows · 3.10 Conclusion · 3.11 Summary

What you learn in chapter 3 →

Chapter 4: GitHub Actions

4.1 Types of actions · 4.1.1 Docker container actions · 4.1.2 JavaScript actions · 4.1.3 Composite actions · 4.2 Authoring actions · 4.2.1 Getting started · 4.2.2 Storing actions in GitHub · 4.2.3 Compatibility with GitHub Enterprise Server · 4.2.4 Release management · 4.3 Hands-on lab: My first Docker container action · 4.3.1 Using the template to create a new repository · 4.3.2 Creating the Dockerfile for the action · 4.3.3 Creating the action.yml file · 4.3.4 Creating the entrypoint.sh script · 4.3.5 Create a workflow to test the container · 4.4 Sharing actions · 4.4.1 Sharing actions in your organization · 4.4.2 Sharing actions publicly · 4.5 Advanced action development · 4.6 Best practices · 4.7 Conclusion · 4.8 Summary

What you learn in chapter 4 →

Chapter 5: Runners

5.1 Targeting a runner · 5.2 Queuing jobs · 5.3 The runner application · 5.4 GitHub-hosted runners · 5.5 Hosted operating systems · 5.6 Installed software · 5.7 Default shells · 5.8 Installing extra software · 5.9 Location and hardware specifications of the hosted runners · 5.10 Concurrent jobs · 5.11 Larger GitHub-hosted runners · 5.12 GitHub-hosted runners in your own Azure Virtual Network · 5.13 Billing GitHub-hosted runners · 5.14 Analyzing the usage of GitHub-hosted runners · 5.15 Self-hosted runners · 5.16 Summary

What you learn in chapter 5 →

Chapter 6: Self-hosted runners

6.1 Setting up self-hosted runners · 6.1.1 Runner communication · 6.1.2 Queued jobs · 6.1.3 Updating self-hosted runners · 6.1.4 Available runners · 6.1.5 Downloading actions and source code · 6.1.6 Runner capabilities · 6.1.7 Self-hosted runner behind a proxy · 6.1.8 Usage limits of self-hosted runners · 6.1.9 Installing extra software · 6.1.10 Runner service account · 6.1.11 Pre- and post-job scripts · 6.1.12 Adding extra information to your logs · 6.1.13 Customizing the containers during a job · 6.2 Security risks of self-hosted runners · 6.3 Single-use runners · 6.3.1 Ephemeral runners · 6.3.2 Just-in-time runners · 6.4 Disabling self-hosted runner creation · 6.5 Autoscaling options · 6.5.1 Autoscaling with Actions Runner Controller · 6.5.2 Communication in ARC · 6.5.3 ARC monitoring · 6.6 Summary

What you learn in chapter 6 →

Chapter 7: Managing your self-hosted runners

7.1 Runner groups · 7.1.1 Assigning a runner to a runner group · 7.2 Monitoring your runners · 7.2.1 What to monitor · 7.2.2 Monitoring available runners using GitHub Actions · 7.2.3 Building a custom solution · 7.2.4 Using a monitoring solution · 7.3 Runner utilization and capacity needs · 7.4 Monitoring network access · 7.4.1 Monitor and limit network access · 7.4.2 Recommended setup · 7.5 Internal billing for action usage · 7.6 Summary

What you learn in chapter 7 →

Chapter 8: Continuous integration

8.1 GloboTicket: A sample application · 8.2 Why continuous integration? · 8.3 Types of CI · 8.3.1 Using a branching strategy: GitHub Flow · 8.3.2 CI for integration · 8.3.3 CI for quality control · 8.3.4 CI for security testing · 8.3.5 CI for packaging · 8.4 Generic CI workflow steps · 8.4.1 Getting the sources · 8.4.2 Building the sources into artifacts · 8.4.3 Testing the artifacts · 8.4.4 Test result reporting · 8.4.5 Using containers for jobs · 8.4.6 Multiple workflows vs. multiple jobs: Which to choose? · 8.4.7 Parallel execution of jobs · 8.5 Preparing for deployment · 8.5.1 Traceability of source to artifacts · 8.5.2 Ensuring delivery integrity: The software bill of materials · 8.5.3 Versioning · 8.5.4 Testing for security with container scanning · 8.5.5 Using GitHub package management and container registry · 8.5.6 Using the upload/download capability to store artifacts · 8.5.7 Preparing deployment artifacts · 8.5.8 Creating a release · 8.6 The CI workflows for GloboTicket · 8.6.1 The integration CI for APIs and frontends · 8.6.2 CI workflows for quality control · 8.6.3 The CI workflow for security testing · 8.6.4 The CI workflows for container image creation and publishing · 8.6.5 Creating a release · 8.7 Conclusion · 8.8 Summary

What you learn in chapter 8 →

Chapter 9: Continuous delivery

9.1 CD workflow steps · 9.1.1 Steps to deploy our GloboTicket application · 9.1.2 Triggering the deployment · 9.1.3 Getting the deployment artifacts · 9.1.4 Deployment · 9.1.5 Verifying the deployment · 9.2 Using environments · 9.2.1 What is an environment? · 9.2.2 Manual approval · 9.2.3 Environment variables · 9.2.4 Dealing with secrets · 9.3 Deployment strategies · 9.3.1 Deploying on premises · 9.3.2 Deploying to cloud · 9.3.3 OpenID Connect (OIDC) · 9.3.4 Using health endpoints · 9.3.5 Deployment vs. release · 9.3.6 Zero-downtime deployments · 9.3.7 Red–green deployments · 9.3.8 Ring-based deployments · 9.4 Summary

What you learn in chapter 9 →

Chapter 10: Security

10.1 Preventing pwn requests · 10.2 Managing untrusted input · 10.3 GitHub Actions security · 10.3.1 The principle of least privileged · 10.3.2 Referencing actions · 10.4 Supply chain security · 10.4.1 Dependabot version updates for actions · 10.4.2 Code scanning actions · 10.5 Summary

What you learn in chapter 10 →

Chapter 11: Compliance

11.1 How to ensure traceability of work · 11.1.1 How to ensure commits are traceable · 11.2 How to enforce the four-eyes principle · 11.2.1 Enforcing segregation of duties with CODEOWNERS file · 11.2.2 Showing end-to-end traceability · 11.3 Mandatory workflows · 11.4 Summary

What you learn in chapter 11 →

Chapter 12: Improving workflow performance and costs

12.1 Dealing with high-volume builds · 12.1.1 Concurrency groups · 12.1.2 Merge queues · 12.2 Reducing the costs of maintaining artifacts · 12.3 Improving performance · 12.3.1 Using a sparse checkout · 12.3.2 Adding caching · 12.3.3 Detecting a cache hit and skipping the work · 12.3.4 Selecting other runners · 12.4 Optimizing your jobs · 12.5 Summary

What you learn in chapter 12 →

Concepts explained in this book

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.