{"id":406288,"date":"2022-02-16T13:00:49","date_gmt":"2022-02-16T10:00:49","guid":{"rendered":"https:\/\/en.buradabiliyorum.com\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/"},"modified":"2022-02-16T13:00:49","modified_gmt":"2022-02-16T10:00:49","slug":"should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it","status":"publish","type":"post","link":"https:\/\/buradabiliyorum.com\/en\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/","title":{"rendered":"#Should You Use Github Actions for Continuous Integration (CI)? \u2013 CloudSavvy IT"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a242e5218106\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #dd3333;color:#dd3333\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #dd3333;color:#dd3333\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a242e5218106\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/buradabiliyorum.com\/en\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/#What_Is_Continuous_Integration\" >What Is Continuous Integration?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/buradabiliyorum.com\/en\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/#What_Are_Github_Actions\" >What Are Github Actions?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/buradabiliyorum.com\/en\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/#Github_Actions_Pricing\" >Github Actions Pricing<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/buradabiliyorum.com\/en\/should-you-use-github-actions-for-continuous-integration-ci-cloudsavvy-it\/#Should_You_Use_Actions_or_Your_Own_Build_Server\" >Should You Use Actions or Your Own Build Server?<\/a><\/li><\/ul><\/nav><\/div>\n<p><strong>&#8220;#Should You Use Github Actions for Continuous Integration (CI)? \u2013 CloudSavvy IT&#8221;<\/strong><\/p>\n<div id=\"article-content-area\">\n<img loading=\"lazy\" decoding=\"async\" class=\"type:primaryImage alignnone size-full wp-image-7125\" data-pagespeed-lazy-srcset=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2020\/10\/d6528811.png?width=398&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1 400w, https:\/\/www.cloudsavvyit.com\/p\/uploads\/2020\/10\/d6528811.png?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1 1200w\" sizes=\"auto, 400w, 1200w\" data-pagespeed-lazy-src=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2020\/10\/d6528811.png?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"\" width=\"700\" height=\"300\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Continuous Integration is crucial for any active repository that needs routine building and testing. Github supports CI pipelines in the form of Github Actions\u2014builds that run in the cloud, automatically, with just a bit of setup.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"What_Is_Continuous_Integration\"><\/span>What Is Continuous Integration?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>While some codebases, like certain web <a href=\"https:\/\/buradabiliyorum.com\/en\/category\/download-scripts-themes-apps\/\" data-internallinksmanager029f6b8e52c=\"9\" title=\"Download Scripts &amp; Themes &amp; Apps\" target=\"_blank\" rel=\"noopener\">app<\/a>s, can be deployed directly from their source files, others require additional processing, compilation, and, most importantly, unit testing. These builds can be complicated and even resource intensive in the case of languages like C++.<\/p>\n<p>Continuous Integration is the process of automating testing and building for new commits to your source code. Commonly, this is used with software like Jenkins running on a \u201cbuild server\u201d that will handle the actual compilation.<\/p>\n<p>Automated code compilation is such a useful service for software teams that it\u2019s now offered by cloud providers, including Github, where it integrates nicely with the rest of their services.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"What_Are_Github_Actions\"><\/span>What Are Github Actions?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/docs.github.com\/en\/actions\">Github Actions<\/a> are cloud-based tasks that can be used to automate your repository. They\u2019re commonly used to run automated builds for new commits or releases, which can be useful for continuous software testing. However, they can also be used for non-CI related automation, such as working with issues and pull requests, running <code>cron<\/code> jobs, or triggering commands based on actions in your account.<\/p>\n<p>As far as CI goes, Github Actions are quite useful. Most CI pipelines require you to set up complicated software like Jenkins or be using a specific cloud service like AWS CodePipeline. Github Actions are very simple, and just require you to commit a configuration file to <code>.github\/workflows\/<\/code>\u00a0to enable an action.<\/p>\n<p>On top of that, Github is usually able to pick up on what kind of project you\u2019re making and offer suggestions for action configs from its library of examples. For example, this Java project was up and running with automated builds in only a few minutes with some minor tweaks to<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-15472\" data-pagespeed-lazy-src=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2022\/01\/5744af11.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"\" width=\"1246\" height=\"891\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>You can have multiple actions in the same repo; for example, maybe you want to set up automated builds for every commit on the <code>dev<\/code>\u00a0branch, but you only want builds for each new tagged release on the <code>master<\/code>\u00a0branch. You can make two separate YAML files with different criteria.<\/p>\n<p>While Actions are very useful for doing builds and testing, they can also run commands and connect with other services, allowing them to automate the delivery and deployment processes as well. For example, you could have an action on the <code>release<\/code>\u00a0branch take each new tagged release and upload it to your servers for deployment.<\/p>\n<p>By default, Github Actions builds will publish build artifacts (whatever was outputted by the build process) to a zip file for each run. This works well if you\u2019re just running tests, but if you want to do automated delivery, you can also set them up to automatically publish new releases, or push to a package\/container registry like NPM or the Docker hub.<\/p>\n<p>The exact configuration for your repository will vary depending on what your build process is, but Github does a good job of providing solid examples to start with, and the <a href=\"https:\/\/buradabiliyorum.com\/en\/category\/general\/\" data-internallinksmanager029f6b8e52c=\"3\" title=\"General\" target=\"_blank\" rel=\"noopener\">general<\/a> setup is largely the same. If you\u2019d like to learn more about getting started with GH Actions, you can read our guide on setting them up.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"Github_Actions_Pricing\"><\/span>Github Actions Pricing<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Fortunately, Github has the money to sponsor open-source software, so Actions are\u00a0<em>entirely free<\/em> for public repositories. You can use them as much as you want, or store as many build artifacts as you want\u2014there\u2019s no hard limit unless you\u2019re being abusive, just like the rest of Github.<\/p>\n<p>For private repositories, every account automatically has 2000 minutes of build time every month, which is very generous. That\u2019s almost a day and a half of continuous building, so you\u2019d have to be doing some seriously long builds\u2014or tons of commits\u2014to hit that number. You\u2019re more likely to hit the\u00a0500 MB storage limit for free accounts. However, if you are building on every commit, with long build times, and committing often, you can run that number out.<\/p>\n<p>Github Pro users ($4\/month) get 3000 minutes and 1 GB of storage, as do organizations using the Github Team plan, which is $4 per user, per month.<\/p>\n<p>Github Enterprise, which costs $21 per user, per month, gives 50,000 minutes of build minutes, which is 35 straight days of builds, letting you run builds 24\/7 and then some.<\/p>\n<p>If you do go over on any plan, you\u2019ll simply be billed for the extra minutes used. The<a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/docs.github.com\/en\/billing\/managing-billing-for-github-actions\/about-billing-for-github-actions\"> rates are pretty fair<\/a>, with an extra 2000 minutes costing $16.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"Should_You_Use_Actions_or_Your_Own_Build_Server\"><\/span>Should You Use Actions or Your Own Build Server?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-3620 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2020\/01\/ffb557e9.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"jenkins logo\" width=\"700\" height=\"300\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>CI\/CD starts with version control tracking. Automated builds are usually run for each commit or major release, and most standalone build server systems, like Jenkins or TeamCity, will integrate with your <code>git<\/code>\u00a0repository to provide this functionality.<\/p>\n<p>This makes Github\u2019s own CI solution pretty useful in comparison\u2014it\u2019s integrated directly into the service you\u2019re already using and is extremely simple to get up and running. All you have to do is commit the build configuration file to your <code>.github<\/code>\u00a0folder, and Github will pick it up and run it. While standalone services can be useful for enterprise deployments, for the average user, the simplicity of using Github Actions is easier than even installing a custom build server.<\/p>\n<p>Github Actions are also able to be used for more than just automated builds. They support all kinds of repository automation, including working with issues and pull requests.<\/p>\n<p>With that said, Github Actions aren\u2019t as full featured as running your own server for it, and if you do a lot of regular or complicated builds, you should look into setting up a Jenkins server. If you do a lot of CPU-intensive builds, Jenkins can also be good for that, but Github Actions also supports using your own server to run builds on.<\/p>\n<p><strong>RELATED:<\/strong> <strong><em>How to Install and Use Jenkins to Build a CI\/CD Pipeline<\/em><\/strong>\n<\/div>\n<blockquote><p><strong><span style=\"color: #ff6600;\">If you liked the article, do not forget to share it with your friends. Follow us on\u00a0<span style=\"color: #ff0000;\"><a style=\"color: #ff0000;\" href=\"https:\/\/news.google.com\/publications\/CAAqBwgKMLG0nwswvr63Aw\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Google News<\/a><\/span>\u00a0too, click on the star and choose us from your favorites.<\/span><\/strong><\/p><\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\">For forums sites go to <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/forum.buradabiliyorum.com\/\" target=\"_blank\" rel=\"noopener\">Forum.BuradaBiliyorum.Com<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\"><strong>If you want to read more like this article, you can visit our <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/en.buradabiliyorum.com\/technology\/\" target=\"_blank\" rel=\"noopener\">Technology category.<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<p><span style=\"color: black;\"><a style=\"color: #ff9900;\" href=\"https:\/\/www.cloudsavvyit.com\/15499\/should-you-use-github-actions-for-continuous-integration-ci\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;#Should You Use Github Actions for Continuous Integration (CI)? \u2013 CloudSavvy IT&#8221; Continuous Integration is crucial for any active repository that needs routine building and testing. Github supports CI pipelines in the form of Github Actions\u2014builds that run in the cloud, automatically, with just a bit of setup. What Is Continuous Integration? While some codebases,&#8230;<\/p>\n","protected":false},"author":1,"featured_media":406289,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"fifu_image_url":"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2020\/10\/d6528811.png","fifu_image_alt":"","footnotes":""},"categories":[18],"tags":[],"class_list":["post-406288","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/406288","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/comments?post=406288"}],"version-history":[{"count":0,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/406288\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media\/406289"}],"wp:attachment":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media?parent=406288"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/categories?post=406288"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/tags?post=406288"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}