반응형
아마존 리눅스를 위한 Docker 설치 스크립트
Docker with Docker Compose
# Docker
sudo yum install -y docker
sudo usermod -aG docker ec2-user
sudo systemctl enable docker
sudo systemctl start docker
sudo systemctl start docker.socket
docker info
# Docker Compose Plugin
sudo mkdir -p /usr/local/lib/docker/cli-plugins/
sudo curl -SL "https://github.com/docker/compose/releases/latest/download/docker-compose-linux-$(uname -m)" -o /usr/local/lib/docker/cli-plugins/docker-compose
sudo chmod +x /usr/local/lib/docker/cli-plugins/docker-compose
docker compose version
docker-compose Command
# docker-compose Command
# Method1 - symlink
sudo ln -s /usr/local/lib/docker/cli-plugins/docker-compose /usr/local/bin/docker-compose
# Method2 - alias
#alias docker-compose='docker compose --compatibility "$@"'
docker-compose version
반응형