Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
A manual functional test environment setup for testing the new code charm-helpers code to handle new Juju proxy settings and keyserver logic
Manual functional test environment (localhost):
juju model-config cloudinit-userdata
- |
# juju tools mirror certificate here
- ip route del default
- bash -c 'echo local-repo.local >> /etc/hosts'
- bash -c 'echo lxd-images.local >> /etc/hosts'
- bash -c 'echo juju-agents.local >> /etc/hosts'
- ip route del default
- bash -c 'echo local-repo.local >> /etc/hosts'
- bash -c 'echo lxd-images.local >> /etc/hosts'
- bash -c 'echo juju-agents.local >> /etc/hosts'
juju model-config
Attribute From Value
agent-metadata-url model https://juju-agents.local/
agent-stream default released
agent-version model 2.4.5
apt-ftp-proxy default ""
apt-http-proxy model
apt-https-proxy model
apt-mirror default ""
apt-no-proxy default ""
automatically-retry-hooks default true
backup-dir default ""
cloudinit-userdata model <value set, see juju model-config cloudinit-userdata>
container-image-metadata-url model https://lxd-images.local/
container-image-stream default released
container-inherit-properties default ""
container-networking-method model local
default-series default bionic
development default false
disable-network-management default false
egress-subnets default ""
enable-os-refresh-update default true
enable-os-upgrade default true
fan-config default ""
firewall-mode default instance
ftp-proxy default ""
http-proxy default ""
https-proxy default ""
ignore-machine-addresses default false
image-metadata-url model https://lxd-images.local/
image-stream default released
juju-ftp-proxy default ""
juju-http-proxy model
juju-https-proxy model
juju-no-proxy default,localhost,::1
logforward-enabled default false
logging-config model <root>=DEBUG;unit=DEBUG
max-action-results-age default 336h
max-action-results-size default 5G
max-status-history-age default 336h
max-status-history-size default 5G
net-bond-reconfigure-delay default 17
no-proxy default,localhost,::1
provisioner-harvest-mode default destroyed
proxy-ssh default false
resource-tags model {}
snap-http-proxy default ""
snap-https-proxy default ""
snap-store-assertions default ""
snap-store-proxy default ""
ssl-hostname-verification default true
storage-default-filesystem-source model lxd
test-mode default false
transmit-vendor-metrics default true
update-status-hook-interval default 5m
# pull the landscape-server charm code and rsync modified charm-helpers there
# trusty and xenial will need
juju deploy ./landscape-charm --series trusty landscape-trusty --config source='deb trusty main' --config key=6E85A86E4652B4E6
juju deploy ./landscape-charm --series xenial landscape-xenial --config source='deb xenial main' --config key=6E85A86E4652B4E6
# add-apt-proxy properly handles proxy environment variables so ppa shortcuts work property
juju deploy ./landscape-charm --series bionic landscape-bionic --config source=ppa:landscape/18.03
root@juju-172242-4:/var/lib/juju/agents/unit-landscape-xenial-0/charm# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.5 LTS
Release: 16.04
Codename: xenial
root@juju-172242-4:/var/lib/juju/agents/unit-landscape-xenial-0/charm# config-get source
deb xenial main
root@juju-172242-4:/var/lib/juju/agents/unit-landscape-xenial-0/charm# config-get key
# no default route - only http/https proxy is available
root@juju-172242-4:/var/lib/juju/agents/unit-landscape-xenial-0/charm# ip route dev eth0 proto kernel scope link src
# just to make sure
ubuntu@juju-172242-4:~$ curl
curl: (7) Couldn't connect to server
root@juju-172242-4:/var/lib/juju/agents/unit-landscape-xenial-0/charm# env | grep PROXY
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 622 100 622 0 0 2251 0 --:--:-- --:--:-- --:--:-- 2253
# ...
unit-landscape-xenial-0: 18:49:44 INFO unit.landscape-xenial/0.juju-log Adding repository: deb xenial main
unit-landscape-xenial-0: 18:49:47 DEBUG worker.uniter.jujuc running hook tool "juju-log"
unit-landscape-xenial-0: 18:49:47 WARNING unit.landscape-xenial/0.juju-log PGP key found (looks like Radix64 format)
unit-landscape-xenial-0: 18:49:47 DEBUG worker.uniter.jujuc running hook tool "juju-log"
unit-landscape-xenial-0: 18:49:47 WARNING unit.landscape-xenial/0.juju-log SECURELY importing PGP key from keyserver; full key not provided.
apt-key list
pub 1024D/437D05B5 2004-09-12
uid Ubuntu Archive Automatic Signing Key <>
sub 2048g/79164387 2004-09-12
pub 4096R/C0B21F32 2012-05-11
uid Ubuntu Archive Automatic Signing Key (2012) <>
pub 4096R/EFE21092 2012-05-11
uid Ubuntu CD Image Automatic Signing Key (2012) <>
pub 1024D/FBB75451 2004-12-30
uid Ubuntu CD Image Automatic Signing Key <>
pub 1024R/4652B4E6 2009-01-18
uid Launchpad PPA for Landscape
On bionic add-apt-repository does everything correctly on its own:
apt-key list
pub rsa1024 2009-01-18 [SC]
35F7 7D63 B5CE C106 C577 ED85 6E85 A86E 4652 B4E6
uid [ unknown] Launchpad PPA for Landscape
pub rsa4096 2012-05-11 [SC]
790B C727 7767 219C 42C8 6F93 3B4F E6AC C0B2 1F32
uid [ unknown] Ubuntu Archive Automatic Signing Key (2012) <>
pub rsa4096 2012-05-11 [SC]
8439 38DF 228D 22F7 B374 2BC0 D94A A3F0 EFE2 1092
uid [ unknown] Ubuntu CD Image Automatic Signing Key (2012) <>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.