Message ID | 20210525105416.2395747-1-jesse.sung@canonical.com |
---|---|
State | New |
Headers | show |
Series | [linux-snap,bionic,master] Copy host trusted.gpg keyring only when it exists | expand |
On 25.05.21 12:54, Wen-chien Jesse Sung wrote: > The file may not be available when the snap doesn't build on Launchpad. > > Signed-off-by: Wen-chien Jesse Sung <jesse.sung@canonical.com> Acked-by: Stefan Bader <stefan.bader@canonical.com> > --- Not quite sure why we would care for changing the makefile which is there to build on launchpad to handle not building on launchpad. But for us building on launchpad it should be a change that does not change anything. -Stefan > Makefile | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/Makefile b/Makefile > index f9137c0..7620b98 100644 > --- a/Makefile > +++ b/Makefile > @@ -93,7 +93,9 @@ prepare-chroot: > cp /etc/apt/sources.list chroot/etc/apt/sources.list > echo "deb http://ppa.launchpad.net/snappy-dev/image/ubuntu $(RELEASE) main" >> chroot/etc/apt/sources.list > # Copy the host's trusted.gpg for ubuntu-esm repositories > - cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg > + if [ -f /etc/apt/trusted.gpg ]; then \ > + cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg; \ > + fi > > # install all updates > $(ENV) chroot chroot apt-get -y update >
On Tue, Jun 1, 2021 at 10:54 PM Stefan Bader <stefan.bader@canonical.com> wrote: > > On 25.05.21 12:54, Wen-chien Jesse Sung wrote: > > The file may not be available when the snap doesn't build on Launchpad. > > > > Signed-off-by: Wen-chien Jesse Sung <jesse.sung@canonical.com> > Acked-by: Stefan Bader <stefan.bader@canonical.com> > > --- > > Not quite sure why we would care for changing the makefile which is there to > build on launchpad to handle not building on launchpad. But for us building on > launchpad it should be a change that does not change anything. Some project snaps use the same master branch but are not built on Launchpad because of the limitations of snap build support of Launchpad. I'd like to keep using the master branch instead of forking it when possible... Thanks, Jesse > > -Stefan > > > Makefile | 4 +++- > > 1 file changed, 3 insertions(+), 1 deletion(-) > > > > diff --git a/Makefile b/Makefile > > index f9137c0..7620b98 100644 > > --- a/Makefile > > +++ b/Makefile > > @@ -93,7 +93,9 @@ prepare-chroot: > > cp /etc/apt/sources.list chroot/etc/apt/sources.list > > echo "deb http://ppa.launchpad.net/snappy-dev/image/ubuntu $(RELEASE) main" >> chroot/etc/apt/sources.list > > # Copy the host's trusted.gpg for ubuntu-esm repositories > > - cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg > > + if [ -f /etc/apt/trusted.gpg ]; then \ > > + cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg; \ > > + fi > > > > # install all updates > > $(ENV) chroot chroot apt-get -y update > > > >
On 25.05.21 12:54, Wen-chien Jesse Sung wrote: > The file may not be available when the snap doesn't build on Launchpad. > > Signed-off-by: Wen-chien Jesse Sung <jesse.sung@canonical.com> > --- Applied to bionic:linux-snap/master. Thanks. -Stefan > Makefile | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/Makefile b/Makefile > index f9137c0..7620b98 100644 > --- a/Makefile > +++ b/Makefile > @@ -93,7 +93,9 @@ prepare-chroot: > cp /etc/apt/sources.list chroot/etc/apt/sources.list > echo "deb http://ppa.launchpad.net/snappy-dev/image/ubuntu $(RELEASE) main" >> chroot/etc/apt/sources.list > # Copy the host's trusted.gpg for ubuntu-esm repositories > - cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg > + if [ -f /etc/apt/trusted.gpg ]; then \ > + cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg; \ > + fi > > # install all updates > $(ENV) chroot chroot apt-get -y update >
diff --git a/Makefile b/Makefile index f9137c0..7620b98 100644 --- a/Makefile +++ b/Makefile @@ -93,7 +93,9 @@ prepare-chroot: cp /etc/apt/sources.list chroot/etc/apt/sources.list echo "deb http://ppa.launchpad.net/snappy-dev/image/ubuntu $(RELEASE) main" >> chroot/etc/apt/sources.list # Copy the host's trusted.gpg for ubuntu-esm repositories - cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg + if [ -f /etc/apt/trusted.gpg ]; then \ + cp /etc/apt/trusted.gpg chroot/etc/apt/trusted.gpg.d/host-trusted.gpg; \ + fi # install all updates $(ENV) chroot chroot apt-get -y update
The file may not be available when the snap doesn't build on Launchpad. Signed-off-by: Wen-chien Jesse Sung <jesse.sung@canonical.com> --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)