From 4ff51b3e6e2eae4811d1e3d92ff1da3e071470bc Mon Sep 17 00:00:00 2001 From: burakberkkeskin Date: Wed, 27 Nov 2024 13:30:04 +0300 Subject: [PATCH 1/5] added increasing the disk size --- .../self-hosted-runner/runner-vm-setup.md | 102 ++++++++++++++++++ 1 file changed, 102 insertions(+) diff --git a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md index 9bf7fe115..02c347fd0 100644 --- a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md +++ b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md @@ -1322,6 +1322,108 @@ ssh -o StrictHostKeyChecking=no appcircle@$(tart ip vm02) - Shutdown `vm02`. - Start offline runners as explained in [Start VM](#start-vm) section. +## Increasing Disk Size for Appcircle runner VM + +If you want to increase the disk size of the Appcircle runner VM, you can follow the instructions below. + +The Appcircle runner VM's default disk size is 200GB. If you need more space, follow the steps below to install Packer and edit the VM configuration. + +### Network Requirements +To download and install the necessary files, your network should allow access to the following URLs: + +1. Packer for macOS: `https://releases.hashicorp.com/packer` +2. Packer Checkpoint API: `https://checkpoint-api.hashicorp.com/v1/check/packer` +4. GitHub API for Packer Plugin Tart: `https://api.github.com/repos/cirruslabs/packer-plugin-tart/git/matching-refs/tags` +6. Packer Plugin Tart for macOS: `https://github.com/cirruslabs/packer-plugin-tart/releases/download` + +### Increasing the Disk Size Using Packer + +- Download and unzip Packer using the following commands: + +```bash +curl -L -O https://releases.hashicorp.com/packer/1.11.2/packer_1.11.2_darwin_arm64.zip && \ +unzip packer_1.11.2_darwin_arm64.zip +``` + +- Create a Packer file (e.g., `appcircle-vm.pkr.hcl`) with the following content to configure the VM: + +```bash +vim appcircle-vm.pkr.hcl +``` + +```hcl +packer { + required_plugins { + tart = { + version = ">= 1.12.0" + source = "github.com/cirruslabs/tart" + } + } +} + +source "tart-cli" "tart" { + vm_base_name = "vm01" + vm_name = "vm01x" + cpu_count = 4 + memory_gb = 8 + disk_size_gb = 250 + ssh_password = "cicd" + ssh_username = "appcircle" + ssh_timeout = "120s" + + // A (hopefully) temporary workaround for Virtualization.Framework's + // installation process not fully finishing in a timely manner + create_grace_time = "30s" +} + +build { + sources = ["source.tart-cli.tart"] + + provisioner "shell" { + inline = [ + "echo 'Disabling spotlight indexing...'", "sudo mdutil -a -i off" + ] + } +} +``` + +:::info +Please update the values below in the `appcircle-vm.pkr.hcl` file: + +- `vm_base_name`: This is a placeholder name for the base VM image you are using. +- `vm_name`: This is a placeholder name for the new VM with the increased disk size. +- `disk_size_gb`: Update According to your requirements. You might need more or less depending on your specific needs. + +::: + +- Install the packer dependencies: + +```bash +./packer init appcircle-vm.pkr.hcl +``` + +- Build the new VM: + +```bash +./packer build appcircle-vm.pkr.hcl +``` + +- Check the new VM configuration using: + +```bash +tart get vm01x +``` + +- You can start the VM, connect with SSH and verify the new disk size using the command below: + +```bash +df -h +``` + +By following these steps, you can increase the disk size of your Appcircle runner VMs. + +Ensure all commands execute successfully and verify the new disk size as needed. + ## Troubleshooting ### Tart list has runner instance in list but I can not SSH into the runner From 604c7090a5eababed277c0f4b079f384a49af602 Mon Sep 17 00:00:00 2001 From: burakberkkeskin Date: Wed, 27 Nov 2024 13:32:07 +0300 Subject: [PATCH 2/5] removed comment line --- .../self-hosted-runner/runner-vm-setup.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md index 02c347fd0..3916402df 100644 --- a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md +++ b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md @@ -1370,9 +1370,6 @@ source "tart-cli" "tart" { ssh_password = "cicd" ssh_username = "appcircle" ssh_timeout = "120s" - - // A (hopefully) temporary workaround for Virtualization.Framework's - // installation process not fully finishing in a timely manner create_grace_time = "30s" } From 910dff1c577001d53d12b5f4f50f56739b7efd96 Mon Sep 17 00:00:00 2001 From: burakberkkeskin Date: Wed, 27 Nov 2024 13:47:22 +0300 Subject: [PATCH 3/5] improved instruction --- .../self-hosted-runner/runner-vm-setup.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md index 3916402df..93ed6743f 100644 --- a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md +++ b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md @@ -1345,7 +1345,7 @@ curl -L -O https://releases.hashicorp.com/packer/1.11.2/packer_1.11.2_darwin_arm unzip packer_1.11.2_darwin_arm64.zip ``` -- Create a Packer file (e.g., `appcircle-vm.pkr.hcl`) with the following content to configure the VM: +- Create a Packer file named `appcircle-vm.pkr.hcl` with the following content to configure the Appcircle runner VM: ```bash vim appcircle-vm.pkr.hcl @@ -1411,7 +1411,7 @@ Please update the values below in the `appcircle-vm.pkr.hcl` file: tart get vm01x ``` -- You can start the VM, connect with SSH and verify the new disk size using the command below: +- After you start the VM and connect with SSH, please verify the new disk size using the command below: ```bash df -h From 1b825cb65d7965cbe79c2a4694ef72e924228939 Mon Sep 17 00:00:00 2001 From: burakberkkeskin Date: Thu, 28 Nov 2024 12:06:57 +0300 Subject: [PATCH 4/5] updated the document for Appcircle CDN urls and files --- .../self-hosted-runner/runner-vm-setup.md | 35 +++++++++---------- 1 file changed, 16 insertions(+), 19 deletions(-) diff --git a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md index 93ed6743f..3bbe4ef39 100644 --- a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md +++ b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md @@ -1329,20 +1329,25 @@ If you want to increase the disk size of the Appcircle runner VM, you can follow The Appcircle runner VM's default disk size is 200GB. If you need more space, follow the steps below to install Packer and edit the VM configuration. ### Network Requirements -To download and install the necessary files, your network should allow access to the following URLs: +To download and install the necessary files, your network should allow access to the Appcircle CDN URL: -1. Packer for macOS: `https://releases.hashicorp.com/packer` -2. Packer Checkpoint API: `https://checkpoint-api.hashicorp.com/v1/check/packer` -4. GitHub API for Packer Plugin Tart: `https://api.github.com/repos/cirruslabs/packer-plugin-tart/git/matching-refs/tags` -6. Packer Plugin Tart for macOS: `https://github.com/cirruslabs/packer-plugin-tart/releases/download` +- `https://cdn.appcircle.io` ### Increasing the Disk Size Using Packer - Download and unzip Packer using the following commands: ```bash -curl -L -O https://releases.hashicorp.com/packer/1.11.2/packer_1.11.2_darwin_arm64.zip && \ -unzip packer_1.11.2_darwin_arm64.zip +curl -L -O https://cdn.appcircle.io/self-hosted/runner/packer/1.11.2/packer-darwin-arm64.zip && \ +unzip packer-darwin-arm64.zip +``` + +- Download and unzip the Packer Tart plugin: + +```bash +mkdir -p ~/.config/packer/plugins/github.com/cirruslabs/tart && \ +curl -L -O https://cdn.appcircle.io/self-hosted/runner/packer-plugin-tart/1.14.0/packer-plugin-tart-darwin-arm64.zip && \ +unzip packer-plugin-tart-darwin-arm64.zip -d ~/.config/packer/plugins/github.com/cirruslabs/tart ``` - Create a Packer file named `appcircle-vm.pkr.hcl` with the following content to configure the Appcircle runner VM: @@ -1393,25 +1398,17 @@ Please update the values below in the `appcircle-vm.pkr.hcl` file: ::: -- Install the packer dependencies: - -```bash -./packer init appcircle-vm.pkr.hcl -``` - - Build the new VM: ```bash ./packer build appcircle-vm.pkr.hcl ``` -- Check the new VM configuration using: - -```bash -tart get vm01x -``` +- Start the new VM, connect via SSH, and verify the new disk size with the provided command. -- After you start the VM and connect with SSH, please verify the new disk size using the command below: +:::tip +The command for starting the Appcircle runner VM may vary depending on the Appcircle VM version you are using. For a quick reference, you can check the [configure base runner vm](#configure-base-runner-vms) section. +::: ```bash df -h From 7bcbce6dde513b14de025a7983e9b750187b419e Mon Sep 17 00:00:00 2001 From: burakberkkeskin Date: Thu, 28 Nov 2024 12:12:25 +0300 Subject: [PATCH 5/5] removed last sentence --- .../self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md index 3bbe4ef39..f49f299a9 100644 --- a/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md +++ b/docs/self-hosted-appcircle/self-hosted-runner/runner-vm-setup.md @@ -1416,8 +1416,6 @@ df -h By following these steps, you can increase the disk size of your Appcircle runner VMs. -Ensure all commands execute successfully and verify the new disk size as needed. - ## Troubleshooting ### Tart list has runner instance in list but I can not SSH into the runner