Skip to content
Snippets Groups Projects
Commit 5ca647e9 authored by Ludovico de Nittis's avatar Ludovico de Nittis
Browse files

Add support to install additional packages to the base chroot


This gives us a way to drop in configuration changes (in particular apt
pinning preferences) as soon as possible after the debootstrap run,
allowing non-default pinning to be used to install the extra packages
for the Platform and SDK.

Please note that `$keyringpackage`, and the automatic installation of
`apt-transport-https`, have been removed because this new option can be
considered a generalization of both of them.
So if your suite needs `apt-transport-https`, or if you were using
`$keyringpackage`, list the needed packages with the
`additional_base_packages` option instead.

Signed-off-by: default avatarLudovico de Nittis <ludovico.denittis@collabora.com>
parent 27275c55
No related branches found
No related tags found
1 merge request!14Pull the new upstream Flatdeb changes and use additional_base_packages
......@@ -6,7 +6,7 @@
{{- $mirror := or .mirror "http://deb.debian.org/debian" -}}
{{- $mergedusr := or .mergedusr "false" }}
{{- $keyring := or .keyring "" -}}
{{- $keyringpackage := or .keyringpackage "" -}}
{{- $additional_base_packages := or .additional_base_packages "" -}}
{{- $build_id := or .build_id "" -}}
{{- $variant := or .variant "Minimal base system" -}}
{{- $variant_id := or .variant_id "base" -}}
......@@ -39,9 +39,6 @@ actions:
{{ else }}
check-gpg: false
{{ end }}
{{ if $keyringpackage }}
keyring-package: {{ $keyringpackage }}
{{ end }}
{{ if eq $mergedusr "true" }}
merged-usr: true
{{ else }}
......@@ -71,13 +68,11 @@ actions:
chroot: false
command: 'find "$ROOTDIR/etc/apt" -ls'
{{ if $additional_base_packages }}
- action: apt
recommends: false
packages:
- apt-transport-https
{{ if $keyringpackage }}
- {{ $keyringpackage }}
{{ end }}
packages: {{ $additional_base_packages }}
{{ end }}
- action: run
label: disable-services
......
......@@ -853,6 +853,13 @@ class Builder:
self.escape_variant_id(self.variant_id)
))
add_pkgs = self.suite_details.get('additional_base_packages')
if add_pkgs:
argv.append('-t')
argv.append('additional_base_packages:{}'.format(
self.yaml_dump_one_line(add_pkgs)
))
for keyring in self.apt_keyrings:
if os.path.exists(os.path.join('suites', keyring)):
keyring = os.path.join('suites', keyring)
......
---
additional_base_packages:
- apt-transport-https
apt_components:
- main
- contrib
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment