(22)
https://docs.docker.com/engine/install/ubuntu/
https://zenn.dev/shimakaze_soft/articles/02aebaedeb43b6
https://docs.docker.com/compose/install/compose-plugin/#install-the-plugin-manually
-- 1. Dockerのインストール
sudo apt remove docker docker-engine docker.io containerd runc
sudo apt update
sudo apt install \
ca-certificates \
curl \
gnupg \
lsb-release
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt update
sudo apt install docker-ce docker-ce-cli containerd.io docker-compose-plugin
sudo docker run hello-world
sudo docker image ls
sudo usermod -aG docker ubuntu
docker run hello-world
-- 2. Docker Composeのインストール
sudo curl -SL https://github.com/docker/compose/releases/download/v2.7.0/docker-compose-linux-x86_64 -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
docker-compose -v
vim docker-compose.yml
version: '3'
services:
hello_world:
image: hello-world:latest
docker-compose up
docker-compose ps
docker-compose down -v
(11)
https://docs.docker.com/engine/install/debian/
-- 1. Dockerのインストール
apt remove docker docker-engine docker.io containerd runc
apt update
apt install \
ca-certificates \
curl \
gnupg \
lsb-release
mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
apt update
apt install docker-ce docker-ce-cli containerd.io docker-compose-plugin
docker run hello-world
docker image ls
-- 2. Docker Composeのインストール
curl -SL https://github.com/docker/compose/releases/download/v2.7.0/docker-compose-linux-x86_64 -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker-compose -v
vim docker-compose.yml
version: '3'
services:
hello_world:
image: hello-world:latest
docker-compose up
docker-compose ps
docker-compose down -v
(7)
https://docs.docker.com/engine/install/centos/
-- 1. Dockerのインストール
yum remove docker \
docker-client \
docker-client-latest \
docker-common \
docker-latest \
docker-latest-logrotate \
docker-logrotate \
docker-engine
yum-config-manager \
--add-repo \
https://download.docker.com/linux/centos/docker-ce.repo
yum install docker-ce docker-ce-cli containerd.io docker-compose-plugin
systemctl start docker
systemctl status docker
docker run hello-world
docker image ls
-- 2. Docker Composeのインストール
curl -SL https://github.com/docker/compose/releases/download/v2.7.0/docker-compose-linux-x86_64 -o /usr/local/bin/docker-compose
chmod +x /usr/local/bin/docker-compose
docker-compose -v
vim docker-compose.yml
version: '3'
services:
hello_world:
image: hello-world:latest
docker-compose up
docker-compose ps
docker-compose down -v
- Windows Server
(2019)
https://zenn.dev/humi3/articles/29c99753544443d28e9f
-- 1. Dockerのインストール
Install-Module -Name DockerMsftProvider -Repository PSGallery -Force
Install-Package -Name docker -ProviderName DockerMsftProvider
Restart-Computer -Force
docker version
docker run hello-world
docker image ls
-- 2. Docker Composeのインストール
Invoke-WebRequest "https://github.com/docker/compose/releases/download/v2.9.0/docker-compose-windows-x86_64.exe" -UseBasicParsing -OutFile $Env:ProgramFiles\docker\docker-compose.exe
docker-compose -v
notepad docker-compose.yml
version: '3'
services:
hello_world:
image: hello-world:latest
docker-compose up
docker-compose ps
docker-compose down -v