Add files to directory an keeping CID of directory

Hi all.

I’m new to IPFS and currently are struggeling with organizing files in an directory. What I want to achieve is to get links with the following pattern for different files:

https://ipfs.io/ipfs/CID-of-directory/filename

This does work if I upload an directory with multiple files in it. When I add new Files to this directory the new file is only available through a link with a new CID for the directory.
How is it possible to keep the CID of the directory while adding or updating files in it?
Thanks for your help!!

Greetings

Oh hi Mark, as you modify the content (add files to the directory), the content identifier (CID) changes. That being said, you can look into IPNS to achieve what you want.

Hi McSinyx.

Thanks for your answer. Led me to the wright way! :slight_smile: Found the solution with DNSLink.

Greetings