Subpasses Multiple Attachments & Textures


I want to understand subpasses and implement a rendering to cubemap.

I have 1 Framebuffer, 6 Textures(Layers), 6 Attachments(corresponds to Layer), 6 Subpasses with attachment reference indices.

The dependencies are hard for me to understand, I have a tinkered a bit and but have no actual idea how to connect them. In my opinion they should be independent, however the single framebuffer may cause problems so I have the connected from extern - 1 - 6 - extern.

The render pass iterates over the sub passes via cmdNextSubpass

I notice that the first face gets cleared but I cannot force the clearing of another.
Sometimes it crashes with write violations.

I am curious if the whole setup is nonsense of if I am missing something that will make this approach actually work.
Best Regards

Src Code: