Install Docker Compose Bash Code

title: ## Contents 
style: nestedList # TOC style (nestedList|inlineFirstLevel)
minLevel: 1 # Include headings from the specified level
maxLevel: 4 # Include headings up to the specified level
includeLinks: true # Make headings clickable
debugInConsole: false # Print debug info in Obsidian console

Overview

Sources:

Code Snippet

#!/usr/bin/env bash
 
# apt update
sudo apt-get update
 
# apt install dependencies
sudo apt-get install -y ca-certificates curl
 
# install keyrings
sudo install -m 0755 -d /etc/apt/keyrings
 
# add docker official gpg key
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
 
# add repository to apt sources
echo \
  "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
  $(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
  sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
 
# apt update
sudo apt-get update
 
# apt install docker
sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
 
# verify docker installation
sudo docker --version

See Also


Appendix

Note created on 2024-05-03 and last modified on 2024-05-03.

LIST FROM [[Bash - Install Docker Compose]] AND -"CHANGELOG" AND -"04-RESOURCES/Code/Bash/Bash - Install Docker Compose"

(c) No Clocks, LLC | 2024