Charm deployment to OSM fails
Metadata
Current evaluation
Maintainer facundobatista closed it as not charmcraft-related: bundle.yaml pointed at a build directory, not the generated powerdns.charm. Reporter confirmed deploying works after using the .charm file path.
Resolution: closed not a bug
Reason: facundobatista closed the issue after determining the failure came from the user's OSM bundle configuration rather than charmcraft 1.2.1. The reporter later confirmed (2021-09-16) that changing `charm: ./charms/powerdns-operator` to `charm: ./charms/powerdns-operator/powerdns.charm` made the deployment succeed, i.e. the build output was fine and the archive ambiguity was caused by passing a directory instead of the .charm file.
Evaluated by: mr-cal-bot
No scores available.
Issue body
Hello,
I am trying to deploy the powerDNS CNF to OSM and fails by giving me the following error:
`error":"cannot upload charm: cannot read charm archive: invalid charm archive: ambiguous root directory","error-code":"bad request`.
I am using charmcraft version 1.2.1 and I was able to deploy the same charm in charmcraft version 1.1.1 .
The **bundle.yaml** I am using is the following one:
```
description: PowerDNS Bundle
bundle: kubernetes
series: kubernetes
applications:
powerdns:
charm: ./charms/powerdns-operator
scale: 1
mariadb-k8s:
charm: cs:~charmed-osm/mariadb-k8s
scale: 1
options:
user: youruser
password: yourpass
database: yourdatabase
root_password: yourootpassword
mysql_port: "3306"
relations:
- - mariadb-k8s:mysql
- powerdns:db
```
And the **metadata.yaml** is the following one:
```name: powerdns
description: |
Kubernetes operator for PowerDNS
summary: |
PowerDNS is a DNS server program, written in C++ and licensed under the GPL.
It runs on most Unix derivatives. PowerDNS features a large number of different
backends ranging from simple BIND style zonefiles to relational databases and
load balancing/failover algorithms.
series:
- kubernetes
deployment:
type: stateless
service: loadbalancer
requires:
db:
interface: mysql
limit: 1
```
Any ideas on how to fix that issue would be appreciated.
Thanks in advance,
Fotis
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed not a bug | Maintainer facundobatista closed it as not charmcraft-related: bundle.yaml pointed at a build directory, not the generated powerdns.charm. Reporter confirmed deploying works after using the .charm file path. | |
| stealth/space-bunny-alpha | — | closed not a bug | Deployment succeeded after bundle.yaml specified the generated powerdns.charm file instead of its directory. Closed as a deployment configuration issue, not a Charmcraft bug. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Deployment failed due to ambiguous root directory error. Fixed by updating bundle.yaml to point to the exact .charm file. Maintainer closed it as an OSM config issue, not a charmcraft bug. | |
| qwen/qwen3.6-35b-a3b | — | — | Resolved by user. OSM deployment failed because bundle.yaml pointed to a directory instead of the .charm file. Updating the path to the exact .charm file fixed the ambiguous root directory error and enabled successful deployment. | |
| qwen/qwen3.6-35b-a3b | — | — | Resolved by user. bundle.yaml pointed to a directory instead of the exact .charm file. Changing the path to ./charms/powerdns-operator/powerdns.charm fixed the ambiguous root directory error and completed deployment successfully. | |
| qwen/qwen3.6-35b-a3b | — | — | Deployment failed due to an incorrect charm path in bundle.yaml. The user fixed the ambiguous root directory error by pointing to the exact generated .charm file. Resolved via user configuration; issue closed. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Deployment failed due to an incorrect charm path in bundle.yaml. The user resolved the issue by specifying the exact .charm file instead of the directory. Issue closed as a user-reported configuration fix. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #792 22.10 - Failed to build charm for bases index '0'. | charmcraft | closed | Reporter's reactive charm failed to build; maintainer facundobatista closed it as not a Charmcraft bug — the legacy `charm` tool rejects metadata.yaml without a `series` list. Author agreed and took it to the Juju team. | |
| #249 `charmcraft build` will let you build a charm that won't deploy | charmcraft | closed | Closed by facundobatista as a duplicate, tracking all build-time sanity checks (incl. config.yaml/actions.yaml validity) in the umbrella issue charmcraft#27; later implemented by merged PR #556 (a585aec6). |