Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

Background

Setup machine after creation in a hypervisor or Cloud infrastructure.

Repositories


RepositoryDescription
1https://github.com/tenzin-io/setup-machine.git
  • Setup the machine after installation of the operating system.
  • The bare necessities as a tenzin.io machine.
2https://github.com/tenzin-io/setup-dockerhost.git
  • Setup the machine as a Docker host.
  • Includes my version of the daemon.json file and installs docker-compose binary.

Debian and Ubuntu

Configure machine

Code Block
languagebash
# install packages
apt-get update && apt install -y ansible git

git clone https://github.com/tenzin-io/setup-machine.git
cd setup-machine
./main.yml
cd ..

git clone https://github.com/tenzin-io/setup-dockerhost.git
cd setup-dockerhost
./main.yml
cd ..

Setup as Github actions runner

The below walkthrough can also be found under GitHub account profile → Actions → Runner configuration page.

Linux arm64

Code Block
languagebash
# Create a folder
mkdir actions-runner && cd actions-runner

# Download the latest runner package
curl -o actions-runner-linux-arm64-2.290.1.tar.gz -L https://github.com/actions/runner/releases/download/v2.290.1/actions-runner-linux-arm64-2.290.1.tar.gz

# Optional: Validate the hash
echo "640596ec55df33efe1fff086e1379c1108cba6656791807708cdb664de51fb01  actions-runner-linux-arm64-2.290.1.tar.gz" | shasum -a 256 -c

# Extract the installer
tar xzf ./actions-runner-linux-arm64-2.290.1.tar.gz

# Interactive configuration of actions runner
./config.sh --url https://github.com/tenzin-io --token <GITHUB TOKEN>

# Install as a service
sudo ./svc.sh install
sudo ./svc.sh start
sudo ./svc.sh status

Linux amd64

Code Block
languagebash
# Create a folder
mkdir actions-runner && cd actions-runner

# Download the latest runner package
curl -o actions-runner-linux-x64-2.290.1.tar.gz -L https://github.com/actions/runner/releases/download/v2.290.1/actions-runner-linux-x64-2.290.1.tar.gz

# Optional: Validate the hash
echo "2b97bd3f4639a5df6223d7ce728a611a4cbddea9622c1837967c83c86ebb2baa  actions-runner-linux-x64-2.290.1.tar.gz" | shasum -a 256 -c

# Extract the installer
tar xzf ./actions-runner-linux-x64-2.290.1.tar.gz

# Interactive configuration of actions runner
./config.sh --url https://github.com/tenzin-io --token <GITHUB TOKEN>

# Install as a service
sudo ./svc.sh install
sudo ./svc.sh start
sudo ./svc.sh status