Conversation
| install_docker() { | ||
| apt-get update -y | ||
| apt-get install -y docker-ce docker-ce-cli containerd.io docker-compose-plugin | tee -a $LOG_FILE | ||
| apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin | tee -a $LOG_FILE |
There was a problem hiding this comment.
why add buildx-plugin? does ubuntu need it and debian doesnt?
There was a problem hiding this comment.
The script dappnode_install_pre is executed both in Debian and Ubuntu. I added it because it is recommended here: https://docs.docker.com/engine/install/ubuntu/#install-using-the-repository and we also use it to build packages for several architectures
| [ -f "/usr/bin/xz" ] || ( apt-get install -y xz-utils) | ||
| [ -f "/usr/bin/xz" ] || (apt-get install -y xz-utils) | ||
|
|
||
| # Not working in Ubuntu ISO because the user is not created before executing late-commands |
There was a problem hiding this comment.
if it is not working in ubuntu and has to be done in dappnode_install.sh, shouldnt we only add user in docker group only if NOT in ubuntu? to avoid unnecessary warning or errors
There was a problem hiding this comment.
In Ubuntu it will just not be executed because the user with ID 1000 does not exist yet.
| fi | ||
|
|
||
| echo -e "\e[32mAdding user to docker group...\e[0m" 2>&1 | tee -a $LOGFILE | ||
| addUserToDockerGroup |
There was a problem hiding this comment.
if all distros (debian, ubuntu..) call addUserToDockerGroup() here, we can remove it from dappnode_install_pre.sh right?
| - name: Get SHA-256 Debian attended | ||
| id: shasum-ubuntu-attended | ||
| run: | | ||
| echo -en "# Versions\n| Package | Version |\n|---|---|\nbind.dnp.dappnode.eth|${BIND_VERSION}|\n|ipfs.dnp.dappnode.eth|${IPFS_VERSION}|\n|vpn.dnp.dappnode.eth |${VPN_VERSION}|\n|dappmanager.dnp.dappnode.eth|${DAPPMANAGER_VERSION}|\n|wifi.dnp.dappnode.eth|${WIFI_VERSION}|\n|https.dnp.dappnode.eth|${HTTPS_VERSION}|\n|wireguard.dnp.dappnode.eth|${WIREGUARD_VERSION}|\n# Changes\nChanges implemented in release ${CORE_VERSION}\n# Attended version\nInstall and customize DAppNode using the attended ISO: **DAppNode-${CORE_VERSION}-debian-bookworm-amd64.iso**\n\n## ISO SHA-256 Checksum\n\`\`\`\nshasum -a 256 DAppNode-${CORE_VERSION}-debian-bookworm-amd64.iso\n${SHASUM_ATTENDED}\n\`\`\`\n# Unattended version\nInstall DAppNode easily using the unattended ISO: **DAppNode-${CORE_VERSION}-debian-bookworm-amd64-unattended.iso**\nDo a reboot right after the installation\n:warning: **Warning**: This ISO will install Dappnode automatically, deleting all existing partitions on the disk\n\ndefault login data:\n - **__user__**: dappnode\n - **__password__**: dappnode.s0\n## ISO SHA-256 Checksum\n\`\`\`\nshasum -a 256 DAppNode-${CORE_VERSION}-debian-bookworm-amd64-unattended.iso\n${SHASUM_UNATTENDED}\n\`\`\`\n# DAppNode for Raspberry Pi 4 64bit\n[Instructions](https://github.com/dappnode/DAppNode/wiki/DAppNodeARM-Installation-Guide)\n\ndefault login data:\n - **__user__**: dappnode\n - **__password__**: dappnodepi" > CHANGELOG.md |
There was a problem hiding this comment.
I think I mistakenly removed this
| run: | | ||
| cp ./images/DAppNode-debian-bookworm-amd64.iso DAppNode-${CORE_VERSION}-debian-bookworm-amd64.iso | ||
| file=$(ls images/Dappnode-debian-*.iso) | ||
| attended_filename="${file/images\/Dappnode-/Dappnode-${CORE_VERSION}-}" |
| - name: Set Ubuntu Dappnode unattended ISO name | ||
| run: | | ||
| cp ./images/DAppNode-debian-bookworm-amd64.iso DAppNode-${CORE_VERSION}-debian-bookworm-amd64-unattended.iso | ||
| file=$(ls images/Dappnode-ubuntu-*.iso) |
There was a problem hiding this comment.
samer, why this change?
| core_filename="${file/images\/Dappnode-/Dappnode-${CORE_VERSION}-}" | ||
| unattended_filename="${core_filename/%.iso/-unattended.iso}" | ||
|
|
||
| mv "$file" "$unattended_filename" |
| # Ubuntu ISO UNATTENDED | ||
| - name: Build Ubuntu unattended | ||
| run: | | ||
| sed -i -e "/BASE_OS/s/ubuntu/debian/" docker-compose.yml |
There was a problem hiding this comment.
Should be done in a different PR, looks weird to edit compose env instead of running something like docker compose run --env see https://docs.docker.com/compose/environment-variables/set-environment-variables/#set-environment-variables-with-docker-compose-run---env
.github/workflows/artifacts.yml
Outdated
| sed -i -e "/UNATTENDED/s/true/false/" docker-compose.yml | ||
| docker-compose build | ||
| docker-compose up | ||
| docker-compose up --build |
There was a problem hiding this comment.
we should consider using new docker compose instead of legacy docker-compose
| touch /usr/src/app/dappnode/iso_install.log | ||
|
|
||
| /usr/src/app/iso/scripts/generate_dappnode_iso_debian.sh | ||
| if [ "$BASE_OS" = "ubuntu" ]; then |
There was a problem hiding this comment.
I would say its cleaner to do something like
/usr/src/app/iso/scripts/${BASE_OS}.sh|
|
||
| # The main user needs to be added to the docker group to be able to run docker commands without sudo | ||
| # Explained in: https://docs.docker.com/engine/install/linux-postinstall/ | ||
| addUserToDockerGroup() { |
There was a problem hiding this comment.
should this be done in the installer or pre-requisites script and why?
| } | ||
|
|
||
| # The main user needs to be added to the docker group to be able to run docker commands without sudo | ||
| # Explained in: https://docs.docker.com/engine/install/linux-postinstall/ |
There was a problem hiding this comment.
we should stop relying on upstream documentation that may change at any time and start using something dynamic like https://github.com/docker/docker-install/tree/master
| } | ||
|
|
||
|
|
||
| add_docker_repo() { |
There was a problem hiding this comment.
same as above, we should be using something like https://github.com/docker/docker-install/tree/master
|
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions! |
|
This issue or pull request has been automatically been closed due to inactivity. |
This PR aims to provide a new dappnode ISO image based on Ubuntu, instead of Debian