Fixed comments in cloud-init's examples

This commit is contained in:
Michele Cereda
2022-11-27 12:07:51 +01:00
parent 09007d76a5
commit 09519cfbc2
2 changed files with 25 additions and 18 deletions

View File

@@ -1,19 +1,21 @@
#cloud-config
# Upgrade the instance.
# Deactivated, as this could take a long time if the image is old.
#
# Sources:
# - https://github.com/trajano/terraform-docker-swarm-aws/blob/master/common.cloud-config
# Upgrade the instance
# Deactivated as this could take a long time if the image is old
# https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# https://cloudinit.readthedocs.io/en/latest/topics/examples.html#run-apt-or-yum-upgrade
# - https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# - https://cloudinit.readthedocs.io/en/latest/topics/examples.html#run-apt-or-yum-upgrade
package_upgrade: false
package_reboot_if_required: false
# Install required packages
# This will always update the list of packages, regardless of package_update's value.
# https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# https://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-arbitrary-packages
# Install required packages.
# This will *always* update the list of packages, regardless of the value of the
# 'package_update' setting.
#
# Sources:
# - https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# - https://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-arbitrary-packages
packages:
- jq
- nc

View File

@@ -3,9 +3,7 @@
# Sources:
# - https://github.com/trajano/terraform-docker-swarm-aws/blob/master/common.cloud-config
# Add the Docker repository
# https://cloudinit.readthedocs.io/en/latest/topics/modules.html#yum-add-repo
# https://cloudinit.readthedocs.io/en/latest/topics/examples.html#adding-a-yum-repository
# Add the official Docker repository.
#
# Got from the official installation guide at
# https://docs.docker.com/engine/install/rhel/#install-using-the-repository :
@@ -13,6 +11,10 @@
# yum-config-manager --add-repo \
# https://download.docker.com/linux/rhel/docker-ce.repo && \
# cat /etc/yum.repos.d/docker-ce.repo
#
# Sources:
# - https://cloudinit.readthedocs.io/en/latest/topics/modules.html#yum-add-repo
# - https://cloudinit.readthedocs.io/en/latest/topics/examples.html#adding-a-yum-repository
yum_repos:
docker-ce:
name: Docker CE Stable - $basearch
@@ -22,12 +24,15 @@ yum_repos:
gpgcheck: true
gpgkey: https://download.docker.com/linux/rhel/gpg
# Install required packages
# This will always update the list of packages, regardless of package_update's value.
# https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# https://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-arbitrary-packages
# Install required packages.
# This will *always* update the list of packages, regardless of the value of the
# 'package_update' setting.
#
# docker-ce already depends on docker-ce-cli and containerd.io
# docker-ce already depends on 'docker-ce-cli' and 'containerd.io'
#
# Sources:
# - https://cloudinit.readthedocs.io/en/latest/topics/modules.html#package-update-upgrade-install
# - https://cloudinit.readthedocs.io/en/latest/topics/examples.html#install-arbitrary-packages
packages:
- docker-ce