Comment 0 for bug 1599886

Revision history for this message
Nobuto Murata (nobuto) wrote : apt-mirror does not override security.ubuntu.com

With "apt-mirror"[1] config, juju 1.25 can override archive.ubuntu.com with a local mirror. However security.ubuntu.com in sources.list is untouched. To make charm execution successful without Internet connectivity, replacing security.ubuntu.com with local mirror is essential.

As of 1.25.5, juju generates user-data with apt-mirror as:
====
#cloud-config
apt_mirror: http://localmirror.example.com/ubuntu
====

To override security.ubuntu.com juju needs to generate user-data like:
====
#cloud-config
system_info:
  package_mirrors:
    - arches: [i386, amd64]
      failsafe:
        primary: http://localmirror.example.com/ubuntu
        security: http://localmirror.example.com/ubuntu
      search:
        primary: []
        security: []
====

For more information regarding the override, please refer to [2].

[1] https://jujucharms.com/docs/stable/config-general#apt-mirror
[2] https://bugs.launchpad.net/cloud-init/+bug/1006963