I know I can just create a new and larger luksencrypted container and copy the contents from the previous luks container to the new one, but is there a way to enlarge a luks encrypted container (luks.img)?
I have seen several tutorials on stackexchange such as this: Extend a LUKS encrypted partition to fill disk
However, these are all for luks encrypted partitions, not containers.
cryptsetup
will format and use files, it does not really help you at all in creating or managing them. So it's all up to you how you do it. There are many different ways to change a file's size; I usually do it withtruncate --size
but if you get the size wrong the data is gone... the example shown in Windigo's answer should be safer. And then you still have to resize whatever is encrypted inside the image.