Juju ignores private image mirror settings and tries to fetch the images from Internet
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical Juju |
Triaged
|
High
|
Harry Pidcock | ||
3.3 |
Fix Released
|
High
|
Harry Pidcock |
Bug Description
I have this setup
```bash
# lxc remote ls
+------
| NAME | URL | PROTOCOL | AUTH TYPE | PUBLIC | STATIC | GLOBAL |
+------
| images | https:/
+------
| local (current) | unix:// | lxd | file access | NO | YES | NO |
+------
| ubuntu | https:/
+------
| ubuntu-daily | https:/
+------
| ubuntu-minimal | https:/
+------
| ubuntu-
+------
```
I can list the images on my mirror
```bash
# lxc image list images: | tail
| | ffc039ca79d7 | yes | ubuntu 20.04 LTS armhf (release) (20221213) | armv7l | VIRTUAL-MACHINE | 896.31MiB | Dec 13, 2022 at 12:00am (UTC) |
+------
| | ffcc26d46aa8 | yes | ubuntu 14.04 LTS ppc64el (release) (20160824.1) | ppc64le | VIRTUAL-MACHINE | 251.44MiB | Aug 24, 2016 at 12:00am (UTC) |
+------
| | ffd811035fde | yes | ubuntu 16.04 LTS ppc64el (release) (20180306) | ppc64le | VIRTUAL-MACHINE | 284.31MiB | Mar 6, 2018 at 12:00am (UTC) |
+------
| | fff8772c1526 | yes | ubuntu 16.04 LTS amd64 (release) (20181204) | x86_64 | VIRTUAL-MACHINE | 290.88MiB | Dec 4, 2018 at 12:00am (UTC) |
+------
| | fffaa6f204d8 | yes | ubuntu 16.04 LTS amd64 (release) (20170610) | x86_64 | CONTAINER | 121.25MiB | Jun 10, 2017 at 12:00am (UTC) |
+------
```
Now the problem is that on Juju it seems trying to pull the images from `ubuntu:` instead than from `images:`
```bash
# juju status
[..]
Machine State Address Inst id Base AZ Message
0 down pending ubuntu@22.04 cannot get available image metadata: failed getting published images metadata from default ubuntu cloud images: canno...
```
```bash
controller # less /var/log/
[..]
2024-02-08 23:23:33 INFO juju.worker.
2024-02-08 23:23:36 ERROR juju.worker.
```
This is my juju config
```bash
juju model-config
Attribute From Value
agent-metadata-url controller https:/
agent-stream default released
agent-version model 3.1.7
apt-ftp-proxy default ""
apt-http-proxy default ""
apt-https-proxy default ""
apt-mirror controller http://
apt-no-proxy default ""
automatically-
backup-dir default ""
charmhub-url default https:/
cloudinit-userdata controller <value set, see juju model-config cloudinit-userdata>
container-
container-
container-
container-
controller-
default-base default ""
default-series default ""
default-space default ""
development default false
disable-
disable-telemetry default false
egress-subnets default ""
enable-
enable-os-upgrade default true
fan-config default ""
firewall-mode default instance
ftp-proxy default ""
http-proxy default ""
https-proxy default ""
ignore-
image-metadata-url controller https:/
image-stream default released
juju-ftp-proxy default ""
juju-http-proxy default ""
juju-https-proxy default ""
juju-no-proxy default 127.0.0.
logforward-enabled default false
logging-config model <root>=INFO
logging-output default ""
lxd-snap-channel default 5.0/stable
max-action-
max-action-
max-status-
max-status-
mode default ""
net-bond-
no-proxy default 127.0.0.
num-container-
num-provision-
project default default
provisioner-
proxy-ssh default false
resource-tags model {}
secret-backend default auto
snap-http-proxy default ""
snap-https-proxy default ""
snap-store-
[..]
snap-store-proxy controller <redacted>
snap-store-
ssl-hostname-
storage-
test-mode default false
transmit-
update-
```
Reproduction steps: create an air-gapped environment and point Juju to the local mirror. Then, attempt to deploy Juju in HA or deploy any workload with Juju.
Changed in juju: | |
status: | New → In Progress |
importance: | Undecided → High |
assignee: | nobody → Joseph Phillips (manadart) |
milestone: | none → 3.1.8 |
Changed in juju: | |
milestone: | 3.1.8 → 3.1.9 |
Changed in juju: | |
milestone: | 3.1.9 → 3.1.10 |
I have seen the same issue with Juju 3.3.1 and Juju controller charm revisions 14 and 79.