{"id":73503,"date":"2018-05-22T10:00:59","date_gmt":"2018-05-22T17:00:59","guid":{"rendered":"https:\/\/open.microsoft.com\/?p=73503"},"modified":"2025-01-29T15:38:30","modified_gmt":"2025-01-29T23:38:30","slug":"how-to-create-vsts-agent-azure-aci-terraform","status":"publish","type":"post","link":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/","title":{"rendered":"How to create a custom VSTS agent on Azure ACI with Terraform"},"content":{"rendered":"\n<p>Open source tools, like <a href=\"https:\/\/www.terraform.io\/\">Terraform<\/a> and <a href=\"https:\/\/www.ansible.com\/\">Ansible<\/a>, can be leveraged to implement \u201cinfrastructure as code,\u201d making it easier to continuously build and deploy cloud infrastructure across your applications.<\/p>\n\n\n\n<p>Visual Studio Team Services (VSTS) provides automated pipelines to build, test, and deploy your code to any platform. It uses agents to perform build and release tasks. Creating private agents has the advantage of being able to install the specific software needed for the builds.<\/p>\n\n\n\n<p>To use HashiCorp and Ansible tools for Azure build and release tasks, we will configure a private VSTS agent with a prepared image hosted <a href=\"https:\/\/hub.docker.com\/r\/lenisha\/vsts-agent-infrastructure\/\">on DockerHub<\/a>). This image is based on the Microsoft standard <a href=\"https:\/\/hub.docker.com\/r\/microsoft\/vsts-agent\/\">VSTS agent image<\/a> and extends it with installed Terraform, Packer and Ansible tools.<\/p>\n\n\n\n<p>To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) &#8212; a service that became generally <a href=\"https:\/\/azure.microsoft.com\/en-us\/blog\/azure-container-instances-now-generally-available\/\">available this month<\/a>. ACI provides an easy way to run containers on Azure.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"vsts-agent-pool\">VSTS Agent Pool<\/h2>\n\n\n\n<p>First, create an Agent Pool in your VSTS account named \u201cACI-Pool\u201d &#8212; it will be used by agent registration.&nbsp;To learn more about deploying agents and getting PAT token configuration, refer to&nbsp;our \u201c<a href=\"https:\/\/docs.microsoft.com\/en-us\/vsts\/build-release\/actions\/agents\/v2-linux?view=vsts\">Deploy an agent on Linux<\/a>&#8221; documentation.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"vsts-docker-image-with-infrastructure-tools\">VSTS Docker Image with Infrastructure Tools<\/h2>\n\n\n\n<p>For the pipeline in this post, we built and published at DockerHub an image based on the Microsoft VSTS agent with all the tools (Packer, Terraform, Ansible) pre-installed. For details on the installed tools and Dockerfile refer to: <a href=\"https:\/\/hub.docker.com\/r\/lenisha\/vsts-agent-infrastructure\/\">https:\/\/hub.docker.com\/r\/lenisha\/vsts-agent-infrastructure\/<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"aci-provisioning\">ACI Provisioning<\/h2>\n\n\n\n<p>We will use Terraform available in Azure CloudShell to setup the ACI container group and run the container based on this image. (It could be done from any command line with AZ CLI installed, and az login is performed.)<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open CloudShell and clone the GitRepo containing Terraform template for ACI running custom agent<br>git clone <a href=\"https:\/\/github.com\/lenisha\/vsts-agent-infrastructure.git\">https:\/\/github.com\/lenisha\/vsts-agent-infrastructure.git <\/a><\/li>\n\n\n\n<li>Run terraform init, plan, and apply to create the infrastructure with the following code:<\/li>\n<\/ol>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; auto-links: false; gutter: false; title: ; quick-code: false; notranslate\" title=\"\">\ncd vsts-agent-infrastructure\/terraform\nterraform init\nterraform apply -var vsts-account=<vsts account> -var vsts-token=<pat token>\n<\/pre><\/div>\n\n\n<p>Upon completion verify that the agent is up and running.<\/p>\n\n\n\n<p>Azure Container Instances would look like this:<\/p>\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.webp\" alt=\"agent containers screenshot\" class=\"wp-image-73504 webp-format\" srcset=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.webp 1024w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-300x70.webp 300w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-768x180.webp 768w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-330x77.webp 330w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-800x188.webp 800w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-400x94.webp 400w\" data-orig-src=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png\" data-orig-srcset=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png 1024w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-300x70.png 300w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-768x180.png 768w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-330x77.png 330w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-800x188.png 800w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent-400x94.png 400w\"><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"vsts-agent-pool-reflects-the-new-agent\">VSTS Agent Pool reflects the new Agent:<\/h2>\n\n\n\n<p>The agent will now be \u201conline,\u201d as pictured below.<\/p>\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online.webp\" alt=\"a screenshot of agent showing as online\" class=\"wp-image-73505 webp-format\" srcset=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online.webp 1024w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-300x120.webp 300w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-768x306.webp 768w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-330x131.webp 330w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-800x319.webp 800w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-400x159.webp 400w\" data-orig-src=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online.png\" data-orig-srcset=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online.png 1024w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-300x120.png 300w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-768x306.png 768w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-330x131.png 330w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-800x319.png 800w, https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-2_agent-online-400x159.png 400w\"><\/figure>\n\n\n\n<p>This configuration is a prerequisite for a 2-part tutorial that demonstrates how to continuously build and deploy Azure infrastructure for applications running on Azure. You can start with <a href=\"https:\/\/open.microsoft.com\/2018\/05\/22\/cicd-azure-terraform-ansible-vsts-java-springboot-app\/\">Part 1 here<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Open source tools, like Terraform and Ansible, can be leveraged to implement \u201cinfrastructure as code,\u201d making it easier to continuously build and deploy cloud infrastructure across your applications. Visual Studio Team Services (VSTS) provides automated pipelines to build, test, and deploy your code to any platform. It uses agents to perform build and release tasks.<\/p>\n","protected":false},"author":5562,"featured_media":73504,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"msxcm_post_with_no_image":false,"ep_exclude_from_search":false,"_classifai_error":"","_classifai_text_to_speech_error":"","footnotes":""},"post_tag":[87,160,2272,166,218,223],"content-type":[340],"topic":[2240,2241,2242,2244],"programming-languages":[],"coauthors":[2326],"class_list":["post-73503","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","tag-ansible","tag-linux","tag-microsoft","tag-azure","tag-terraform","tag-visual-studio","content-type-tutorials-and-demos","topic-application-development","topic-cloud","topic-containers","topic-devops","review-flag-1593580428-734","review-flag-1-1593580432-963","review-flag-2-1593580437-411","review-flag-new-1593580248-669"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to create a custom VSTS agent on Azure ACI with Terraform<\/title>\n<meta name=\"description\" content=\"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to create a custom VSTS agent on Azure ACI with Terraform\" \/>\n<meta property=\"og:description\" content=\"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/\" \/>\n<meta property=\"og:site_name\" content=\"Microsoft Open Source Blog\" \/>\n<meta property=\"article:published_time\" content=\"2018-05-22T17:00:59+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-01-29T23:38:30+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"240\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Elena Neroslavskaya\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@OpenAtMicrosoft\" \/>\n<meta name=\"twitter:site\" content=\"@OpenAtMicrosoft\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Elena Neroslavskaya\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 min read\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/\"},\"author\":[{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/author\\\/elena-neroslavskaya\\\/\",\"@type\":\"Person\",\"@name\":\"Elena Neroslavskaya\"}],\"headline\":\"How to create a custom VSTS agent on Azure ACI with Terraform\",\"datePublished\":\"2018-05-22T17:00:59+00:00\",\"dateModified\":\"2025-01-29T23:38:30+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/\"},\"wordCount\":415,\"commentCount\":7,\"publisher\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2018\\\/05\\\/Post-1_image-1_ACI-agent.png\",\"keywords\":[\"Ansible\",\"Linux\",\"Microsoft\",\"Microsoft Azure\",\"Terraform\",\"Visual Studio\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/\",\"url\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/\",\"name\":\"How to create a custom VSTS agent on Azure ACI with Terraform\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2018\\\/05\\\/Post-1_image-1_ACI-agent.png\",\"datePublished\":\"2018-05-22T17:00:59+00:00\",\"dateModified\":\"2025-01-29T23:38:30+00:00\",\"description\":\"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#primaryimage\",\"url\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2018\\\/05\\\/Post-1_image-1_ACI-agent.png\",\"contentUrl\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2018\\\/05\\\/Post-1_image-1_ACI-agent.png\",\"width\":1024,\"height\":240,\"caption\":\"agent containers screenshot\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/2018\\\/05\\\/22\\\/how-to-create-vsts-agent-azure-aci-terraform\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to create a custom VSTS agent on Azure ACI with Terraform\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/\",\"name\":\"Microsoft Open Source Blog\",\"description\":\"Open dialogue about openness at Microsoft \u2013 open source, standards, interoperability\",\"publisher\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#organization\",\"name\":\"Microsoft Open Source Blog\",\"url\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2019\\\/08\\\/Microsoft-Logo.png\",\"contentUrl\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/wp-content\\\/uploads\\\/2019\\\/08\\\/Microsoft-Logo.png\",\"width\":259,\"height\":194,\"caption\":\"Microsoft Open Source Blog\"},\"image\":{\"@id\":\"https:\\\/\\\/opensource.microsoft.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/x.com\\\/OpenAtMicrosoft\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to create a custom VSTS agent on Azure ACI with Terraform","description":"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/","og_locale":"en_US","og_type":"article","og_title":"How to create a custom VSTS agent on Azure ACI with Terraform","og_description":"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.","og_url":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/","og_site_name":"Microsoft Open Source Blog","article_published_time":"2018-05-22T17:00:59+00:00","article_modified_time":"2025-01-29T23:38:30+00:00","og_image":[{"width":1024,"height":240,"url":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png","type":"image\/png"}],"author":"Elena Neroslavskaya","twitter_card":"summary_large_image","twitter_creator":"@OpenAtMicrosoft","twitter_site":"@OpenAtMicrosoft","twitter_misc":{"Written by":"Elena Neroslavskaya","Est. reading time":"2 min read"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#article","isPartOf":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/"},"author":[{"@id":"https:\/\/opensource.microsoft.com\/blog\/author\/elena-neroslavskaya\/","@type":"Person","@name":"Elena Neroslavskaya"}],"headline":"How to create a custom VSTS agent on Azure ACI with Terraform","datePublished":"2018-05-22T17:00:59+00:00","dateModified":"2025-01-29T23:38:30+00:00","mainEntityOfPage":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/"},"wordCount":415,"commentCount":7,"publisher":{"@id":"https:\/\/opensource.microsoft.com\/blog\/#organization"},"image":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#primaryimage"},"thumbnailUrl":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png","keywords":["Ansible","Linux","Microsoft","Microsoft Azure","Terraform","Visual Studio"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/","url":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/","name":"How to create a custom VSTS agent on Azure ACI with Terraform","isPartOf":{"@id":"https:\/\/opensource.microsoft.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#primaryimage"},"image":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#primaryimage"},"thumbnailUrl":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png","datePublished":"2018-05-22T17:00:59+00:00","dateModified":"2025-01-29T23:38:30+00:00","description":"To make your solution more lightweight and to minimize costs for running the agent, we\u2019ll show you how to provision a custom VSTS agent on Azure Container Instance (ACI) -- a service that became generally available this month.","breadcrumb":{"@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#primaryimage","url":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png","contentUrl":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2018\/05\/Post-1_image-1_ACI-agent.png","width":1024,"height":240,"caption":"agent containers screenshot"},{"@type":"BreadcrumbList","@id":"https:\/\/opensource.microsoft.com\/blog\/2018\/05\/22\/how-to-create-vsts-agent-azure-aci-terraform\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/opensource.microsoft.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to create a custom VSTS agent on Azure ACI with Terraform"}]},{"@type":"WebSite","@id":"https:\/\/opensource.microsoft.com\/blog\/#website","url":"https:\/\/opensource.microsoft.com\/blog\/","name":"Microsoft Open Source Blog","description":"Open dialogue about openness at Microsoft \u2013 open source, standards, interoperability","publisher":{"@id":"https:\/\/opensource.microsoft.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/opensource.microsoft.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/opensource.microsoft.com\/blog\/#organization","name":"Microsoft Open Source Blog","url":"https:\/\/opensource.microsoft.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/opensource.microsoft.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2019\/08\/Microsoft-Logo.png","contentUrl":"https:\/\/opensource.microsoft.com\/blog\/wp-content\/uploads\/2019\/08\/Microsoft-Logo.png","width":259,"height":194,"caption":"Microsoft Open Source Blog"},"image":{"@id":"https:\/\/opensource.microsoft.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/OpenAtMicrosoft"]}]}},"msxcm_animated_featured_image":null,"bloginabox_display_generated_audio":false,"distributor_meta":false,"distributor_terms":false,"distributor_media":false,"distributor_original_site_name":"Microsoft Open Source Blog","distributor_original_site_url":"https:\/\/opensource.microsoft.com\/blog","push-errors":false,"_links":{"self":[{"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/posts\/73503","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/users\/5562"}],"replies":[{"embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/comments?post=73503"}],"version-history":[{"count":6,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/posts\/73503\/revisions"}],"predecessor-version":[{"id":97086,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/posts\/73503\/revisions\/97086"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/media\/73504"}],"wp:attachment":[{"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/media?parent=73503"}],"wp:term":[{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/post_tag?post=73503"},{"taxonomy":"content-type","embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/content-type?post=73503"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/topic?post=73503"},{"taxonomy":"programming-languages","embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/programming-languages?post=73503"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/opensource.microsoft.com\/blog\/wp-json\/wp\/v2\/coauthors?post=73503"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}