I would prefer the second approach so we only have one script.
We could make an optional flag for this so if this flag appears (something like ---pkg-cache), use https://security-metadata.canonical.com/pkg-cache/"$i".
This way, if we need a new endpoint in the future we can simply add more supported flags. As we are listing this in services/crons/etc, I feel like having to provide the whole URL is messier.
« Back to merge proposal
I would prefer the second approach so we only have one script.
We could make an optional flag for this so if this flag appears (something like ---pkg-cache), use https:/ /security- metadata. canonical. com/pkg- cache/"$i".
This way, if we need a new endpoint in the future we can simply add more supported flags. As we are listing this in services/crons/etc, I feel like having to provide the whole URL is messier.