Comment 2 for bug 1836226

Revision history for this message
Tim Van Steenburgh (tvansteenburgh) wrote :

Well, it's not really an invalid charm, it's a charm with a lxd profile that requires --force. But I can see your point - you don't know at deployment time if the charm will be installed on lxd later. So you'd have to add --force to add-unit as well.

Anyway, I can see the reasoning behind the current behavior. It's just unfortunate that a "special" profile has repercussions for *every* deployment, not just deployments to lxd. Logically it seems reasonable to assume that a lxd profile would only impact lxd deployments.

In the case of Charmed Kubernetes, it may never be possible to pare the profile down to something that doesn't require --force, due to assumptions made by the upstream k8s binaries. Which means that we'd need to either 1) require --force for every deployment of the charms, regardless of substrate, or 2) not use the embedded lxd profile feature of juju. The former is gross, and the latter makes life difficult for anyone deploying on lxd.

Really not sure what the "correct" solution is, just wanted to open this bug for awareness and discussion. If no changes are planned, it's okay to close as Won't Fix.