Skip to content

Conversation

@ticoombs
Copy link
Collaborator

  • Minor changes needed for Trixie support.
  • Added a warning comment for us around postgres 18+
  • I have not tested ubuntu with the new debian format, as such I specifically targeted debian 13 (trixie) for the deb repo.
  • Updated the examples regarding pgtune link, & notes on the SHM location

Closes: #267

Here we specifically target it as I'm unsure if Ubuntu has support for deb882 (I'm sure it does, but I havn't had time to test it)
This fixes the big warnings people were reporting due to vars files not being found.
This fixes the big warnings people were reporting due to vars files not being found.
@ticoombs ticoombs self-assigned this Dec 28, 2025
@sanatsathaye
Copy link
Contributor

Hi @ticoombs. I tried this PR on my system but ran into quite a few issues actually, around 4-5 different ones...

@ticoombs
Copy link
Collaborator Author

ticoombs commented Jan 3, 2026

Hi @ticoombs. I tried this PR on my system but ran into quite a few issues actually, around 4-5 different ones...

And they were?

My testing might have been slightly different as i skip all SSL configuration as i already had certificates.
I'll spin up a vm or two to test and see whats what, and try and replicate, but if you can let me know what failed in the future that would be great.

edit: oh my... how did these errors even work! Thanks for testing them for me @sanatsathaye

@ticoombs
Copy link
Collaborator Author

ticoombs commented Jan 3, 2026

Validated on debian13 and ubuntu24.04 with VMs. The only thing i installed before running the ansible scripts was ssh (via the installer) so i think its safe to say its okay now.

@sanatsathaye
Copy link
Contributor

sanatsathaye commented Jan 4, 2026

Oh crap, sorry I meant to post another reply but got carried away with something else. That solves a few issues for me. But considering the changes there are quite a few points to take into consideration:

  • Because the playbook is now using deb822_repository, it only works on ansible-core >= 2.15.0. So, the minimum requirement of the playbook needs to be updated (the first pre_task).
  • deb822_repository requires python3-debian package installed, and it was actually not installed on my Debian 13 VPS out of the box. So, it will need to be added in the dependencies section as an additional package.
  • You don't actually need to limit using the deb822_repository module to Debian 13+... It actually works on all supported OS versions in this playbook of Ubuntu and Debian. My suggestion would be to remove the get_url, apt_repository, the new if condition etc completely, it's unnecessary bloat. What you should add is some code before to use the ansible.builtin.file module to create the /etc/apt/keyrings directory with mode 0755 (basically replicating the official docker instructions) -- this directory doesn't exist on some older versions of the supported OSs. That + usage of the new deb822_repository should be enough.

Now, after all the above has been done, also imagine a scenario where it's not a fresh Debian install, this playbook has already been run before on a system.

  • The docker source is already been added to /etc/apt/sources.list.d/download_docker_com_linux_*.list and key at /etc/apt/trusted.gpg.d/docker.asc. Running the playbook will cause problems with the apt installation on the system because now the source + keys will be added again in deb822 format (I faced it on my other system). So, a suggestion would be to add instructions to UPGRADING.md to manually remove the existing source at /etc/apt/sources.list.d/download_docker_com_linux_*.list and key at /etc/apt/trusted.gpg.d/docker.asc before running the playbook if they already exist. Both these files have only been created by this playbook before so it should be safe.
  • Similarly, there is migration from docker-compose (provided by default apt repository) to docker-compose-plugin (provided by the official docker repository). Attempting to install docker-compose-plugin on a system with docker-compose already present will create dependency related issues (again, I faced it on my other system). So, again a suggestion would be to add instructions to UPGRADING.md to manually sudo apt remove docker-compose if it exists and only then run the playbook.

@ticoombs
Copy link
Collaborator Author

ticoombs commented Jan 4, 2026

Thanks! All very valid points, i hadn't thought of the 12->13 upgrade path and rerunning them.

For deb882 I wanted to only touch on Trixie in this PR as I wanted to limit the exposure but I think you are right. We need to either make the change for all apt related distros or none, as the clash will adversely affect users.

Interesting that the server didn't have that installed. When I created a VM from the debian iso, I only chose ssh and "server-tools", (or whatever it was called).

Probably won't be till next week for me to do more testing now. If you want I can add you to my repo and you can update the branch with the changes :p. Otherwise just having someone validate is amazing.

🙇 Thanks again

@sanatsathaye
Copy link
Contributor

No problem. Tbh the earliest I would be able to make the changes myself is Friday but yeah sure you can add me, I can test out on the various distros too.

{% endif %}
volumes:
# starting postgres 18+ this will need to be `/volumes/postgres:/var/lib/postgresql:Z`
# ref: https://github.com/pgautoupgrade/docker-pgautoupgrade?tab=readme-ov-file#error-message-when-mounting-data-to-varlibpostgresqldata-on-postgres-v18
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also don't have any objections to you doing a postgres v18 upgrade here also. Then there's no need for the comment.

Alternatively, just remove this comment and do the postgres v18 upgrade in another PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support Debian Trixie

4 participants