Chuleta para la instalación y configuración de riodelaplata
con AWS Linux 2023 y Docker.
https://docs.aws.amazon.com/linux/al2023/ug/what-is-amazon-linux.html
cat /etc/os-release
https://docs.aws.amazon.com/linux/al2023/ug/managing-repos-os-updates.html
echo latest | tee /etc/dnf/vars/releasever
dnf upgrade
adduser manuel -G wheel
echo "manuel ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/99-manuel
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/set-hostname.html
cp /etc/cloud/cloud.cfg /etc/cloud/cloud.cfg.orig
En /etc/cloud/cloud.cfg
:
preserve_hostname: true
hostnamectl set-hostname riodelaplata.rabade.net
reboot
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/set-time.html
timedatectl set-timezone Mexico/General
dnf install docker
systemctl start docker
docker run hello-world
systemctl enable docker
usermod -a -G docker manuel
https://www.docker.com/blog/how-to-deploy-on-remote-docker-hosts-with-docker-compose/
docker context create riodelaplata --docker "host=ssh://[email protected]"
docker context ls
En local:
docker compose up -d
En riodelaplata
:
docker context use riodelaplata
docker compose -f docker-compose.yml -f docker-compose.prod.yml up
Lisar:
# docker ps
# docker ps -a