[arch-commits] Commit in buildah/trunk (2 files)

Bartłomiej Piotrowski bpiotrowski at archlinux.org
Fri May 11 06:21:52 UTC 2018


    Date: Friday, May 11, 2018 @ 06:21:52
  Author: bpiotrowski
Revision: 320503

1.0-1

Modified:
  buildah/trunk/0001-Revert-ostree-add-selinux-label-for-each-file.patch
  buildah/trunk/PKGBUILD

----------------------------------------------------------+
 0001-Revert-ostree-add-selinux-label-for-each-file.patch |   35 ++++---------
 PKGBUILD                                                 |    8 +-
 2 files changed, 15 insertions(+), 28 deletions(-)

Modified: 0001-Revert-ostree-add-selinux-label-for-each-file.patch
===================================================================
--- 0001-Revert-ostree-add-selinux-label-for-each-file.patch	2018-05-11 06:13:44 UTC (rev 320502)
+++ 0001-Revert-ostree-add-selinux-label-for-each-file.patch	2018-05-11 06:21:52 UTC (rev 320503)
@@ -1,18 +1,8 @@
-From 6b8fffe3e9a8525679b8a653fcd9b05dc2f5984a Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?Bart=C5=82omiej=20Piotrowski?= <b at bpiotrowski.pl>
-Date: Sat, 17 Mar 2018 21:33:23 +0100
-Subject: [PATCH] Revert "ostree: add selinux label for each file"
-
-This reverts commit 9b4510f6d1627c8e53c3303a8fe48ca7842c2ace.
----
- ostree/ostree_dest.go | 60 ++++++---------------------------------------------
- 1 file changed, 7 insertions(+), 53 deletions(-)
-
 diff --git a/ostree/ostree_dest.go b/ostree/ostree_dest.go
-index 1d97daf..c1c8557 100644
+index 2e0d7fcf..a8e879ed 100644
 --- a/ostree/ostree_dest.go
 +++ b/ostree/ostree_dest.go
-@@ -14,31 +14,25 @@ import (
+@@ -15,31 +15,25 @@ import (
  	"os/exec"
  	"path/filepath"
  	"strconv"
@@ -45,7 +35,7 @@
  import "C"
  
  type blobToImport struct {
-@@ -156,7 +150,7 @@ func (d *ostreeImageDestination) PutBlob(stream io.Reader, inputInfo types.BlobI
+@@ -158,7 +152,7 @@ func (d *ostreeImageDestination) PutBlob(ctx context.Context, stream io.Reader,
  	return types.BlobInfo{Digest: computedDigest, Size: size}, nil
  }
  
@@ -54,7 +44,7 @@
  	entries, err := ioutil.ReadDir(dir)
  	if err != nil {
  		return err
-@@ -171,42 +165,13 @@ func fixFiles(selinuxHnd *C.struct_selabel_handle, root string, dir string, user
+@@ -173,42 +167,13 @@ func fixFiles(selinuxHnd *C.struct_selabel_handle, root string, dir string, user
  			continue
  		}
  
@@ -98,16 +88,16 @@
  			if err != nil {
  				return err
  			}
-@@ -262,7 +227,7 @@ func generateTarSplitMetadata(output *bytes.Buffer, file string) (digest.Digest,
+@@ -264,7 +229,7 @@ func generateTarSplitMetadata(output *bytes.Buffer, file string) (digest.Digest,
  	return digester.Digest(), written, nil
  }
  
 -func (d *ostreeImageDestination) importBlob(selinuxHnd *C.struct_selabel_handle, repo *otbuiltin.Repo, blob *blobToImport) error {
 +func (d *ostreeImageDestination) importBlob(repo *otbuiltin.Repo, blob *blobToImport) error {
+ 	// TODO: This can take quite some time, and should ideally be cancellable using a context.Context.
+ 
  	ostreeBranch := fmt.Sprintf("ociimage/%s", blob.Digest.Hex())
- 	destinationPath := filepath.Join(d.tmpDirPath, blob.Digest.Hex(), "root")
- 	if err := ensureDirectoryExists(destinationPath); err != nil {
-@@ -283,7 +248,7 @@ func (d *ostreeImageDestination) importBlob(selinuxHnd *C.struct_selabel_handle,
+@@ -287,7 +252,7 @@ func (d *ostreeImageDestination) importBlob(selinuxHnd *C.struct_selabel_handle,
  		if err := archive.UntarPath(blob.BlobPath, destinationPath); err != nil {
  			return err
  		}
@@ -116,7 +106,7 @@
  			return err
  		}
  	} else {
-@@ -292,7 +257,7 @@ func (d *ostreeImageDestination) importBlob(selinuxHnd *C.struct_selabel_handle,
+@@ -296,7 +261,7 @@ func (d *ostreeImageDestination) importBlob(selinuxHnd *C.struct_selabel_handle,
  			return err
  		}
  
@@ -125,7 +115,7 @@
  			return err
  		}
  	}
-@@ -400,17 +365,6 @@ func (d *ostreeImageDestination) Commit() error {
+@@ -404,17 +369,6 @@ func (d *ostreeImageDestination) Commit(ctx context.Context) error {
  		return err
  	}
  
@@ -143,7 +133,7 @@
  	checkLayer := func(hash string) error {
  		blob := d.blobs[hash]
  		// if the blob is not present in d.blobs then it is already stored in OSTree,
-@@ -418,7 +372,7 @@ func (d *ostreeImageDestination) Commit() error {
+@@ -422,7 +376,7 @@ func (d *ostreeImageDestination) Commit(ctx context.Context) error {
  		if blob == nil {
  			return nil
  		}
@@ -152,6 +142,3 @@
  		if err != nil {
  			return err
  		}
--- 
-2.16.2
-

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2018-05-11 06:13:44 UTC (rev 320502)
+++ PKGBUILD	2018-05-11 06:21:52 UTC (rev 320503)
@@ -2,7 +2,7 @@
 # Maintainer: Bartłomiej Piotrowski <bpiotrowski at archlinux.org>
 
 pkgname=buildah
-pkgver=0.12
+pkgver=1.0
 pkgrel=1
 pkgdesc="A tool which facilitates building OCI images"
 arch=(x86_64)
@@ -11,15 +11,15 @@
 depends=(ostree runc)
 makedepends=('go-pie' 'git' 'bash-bats' 'btrfs-progs' 'device-mapper' 'gpgme'
              'libassuan' 'bzip2' 'go-md2man' 'runc' 'skopeo')
-_commit=e073df11aa75bd20a8e01cad1956e1fabc7c9895  # tags/v0.12
+_commit=1ab80bcd88929a94c52268a5af8443c0055a42cb  # tags/V1.0
 source=(git://github.com/projectatomic/buildah.git#commit=$_commit
         0001-Revert-ostree-add-selinux-label-for-each-file.patch)
 md5sums=('SKIP'
-         'f59d0b2a1def58f509b277706533c393')
+         'aed8c1169e73161220c49de34f1acfdf')
 
 pkgver() {
   cd buildah
-  git describe --tags | sed 's/^v//;s/-/+/g'
+  git describe --tags | sed 's/^[vV]//;s/-/+/g'
 }
 
 prepare() {



More information about the arch-commits mailing list