Update to 31

I also removed one forgotten patch from previous releases.
This commit is contained in:
Ondřej Budai 2021-08-11 14:42:00 +02:00
parent ebe94301dd
commit 2525f95027
No known key found for this signature in database
GPG Key ID: 2EDC02DB69E9C992
4 changed files with 19 additions and 52 deletions

1
.gitignore vendored
View File

@ -20,3 +20,4 @@
/osbuild-composer-28.tar.gz
/osbuild-composer-29.tar.gz
/osbuild-composer-30.tar.gz
/osbuild-composer-31.tar.gz

View File

@ -1,31 +0,0 @@
diff --git a/internal/upload/azure/azure.go b/internal/upload/azure/azure.go
index 8e18fe78..a5d8f857 100644
--- a/internal/upload/azure/azure.go
+++ b/internal/upload/azure/azure.go
@@ -83,7 +83,7 @@ func UploadImage(credentials Credentials, metadata ImageMetadata, fileName strin
// Create page blob URL. Page blob is required for VM images
blobURL := containerURL.NewPageBlobURL(metadata.ImageName)
- _, err = blobURL.Create(ctx, stat.Size(), 0, azblob.BlobHTTPHeaders{}, azblob.Metadata{}, azblob.BlobAccessConditions{})
+ _, err = blobURL.Create(ctx, stat.Size(), 0, azblob.BlobHTTPHeaders{}, azblob.Metadata{}, azblob.BlobAccessConditions{}, azblob.PremiumPageBlobAccessTierNone, azblob.BlobTagsMap{}, azblob.ClientProvidedKeyOptions{})
if err != nil {
return fmt.Errorf("cannot create the blob URL: %v", err)
}
@@ -122,7 +122,7 @@ func UploadImage(credentials Credentials, metadata ImageMetadata, fileName strin
semaphore <- 1
go func(counter int64, buffer []byte, n int) {
defer wg.Done()
- _, err = blobURL.UploadPages(ctx, counter*azblob.PageBlobMaxUploadPagesBytes, bytes.NewReader(buffer[:n]), azblob.PageBlobAccessConditions{}, nil)
+ _, err = blobURL.UploadPages(ctx, counter*azblob.PageBlobMaxUploadPagesBytes, bytes.NewReader(buffer[:n]), azblob.PageBlobAccessConditions{}, nil, azblob.ClientProvidedKeyOptions{})
if err != nil {
err = fmt.Errorf("uploading a page failed: %v", err)
// Send the error to the error channel in a non-blocking way. If there is already an error, just discard this one
@@ -144,7 +144,7 @@ func UploadImage(credentials Credentials, metadata ImageMetadata, fileName strin
default:
}
// Check properties, specifically MD5 sum of the blob
- props, err := blobURL.GetProperties(ctx, azblob.BlobAccessConditions{})
+ props, err := blobURL.GetProperties(ctx, azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
if err != nil {
return fmt.Errorf("getting the properties of the new blob failed: %v", err)
}

View File

@ -4,7 +4,7 @@
%global goipath github.com/osbuild/osbuild-composer
Version: 30
Version: 31
%gometa
@ -17,7 +17,7 @@ It is compatible with composer-cli and cockpit-composer clients.
}
Name: osbuild-composer
Release: 2%{?dist}
Release: 1%{?dist}
Summary: An image building service based on osbuild
# osbuild-composer doesn't have support for building i686 images
@ -47,6 +47,7 @@ BuildRequires: golang(github.com/coreos/go-systemd/activation)
BuildRequires: golang(github.com/deepmap/oapi-codegen/pkg/codegen)
BuildRequires: golang(github.com/go-chi/chi)
BuildRequires: golang(github.com/google/uuid)
BuildRequires: golang(github.com/jackc/pgx/v4)
BuildRequires: golang(github.com/julienschmidt/httprouter)
BuildRequires: golang(github.com/getkin/kin-openapi/openapi3)
BuildRequires: golang(github.com/kolo/xmlrpc)
@ -54,10 +55,12 @@ BuildRequires: golang(github.com/labstack/echo/v4)
BuildRequires: golang(github.com/gobwas/glob)
BuildRequires: golang(github.com/google/go-cmp/cmp)
BuildRequires: golang(github.com/gophercloud/gophercloud)
BuildRequires: golang(github.com/prometheus/client_golang/prometheus/promhttp)
BuildRequires: golang(github.com/stretchr/testify/assert)
BuildRequires: golang(github.com/ubccr/kerby)
BuildRequires: golang(github.com/vmware/govmomi)
BuildRequires: golang(cloud.google.com/go)
BuildRequires: golang(gopkg.in/ini.v1)
%endif
Requires: %{name}-core = %{version}-%{release}
@ -94,22 +97,6 @@ Obsoletes: osbuild-composer-koji <= 23
%goprep
%endif
%if 0%{?fedora} && 0%{?fedora} <= 32
# Fedora 32 and older ships different kolo/xmlrpc and azure/azblob APIs. We
# cannot specify build tags in gobuild macro because the macro itself
# specifies build tags and -tags argument cannot be used more than once.
# Therefore, this ugly hack with build tags switcharoo is required.
# Remove when F32 is EOL.
# Remove the build constraint from the wrappers of the old APIs
sed -i "s$// +build kolo_xmlrpc_oldapi$// +build !kolo_xmlrpc_oldapi$" internal/upload/koji/xmlrpc-response-oldapi.go
sed -i "s$// +build azblob_oldapi$// +build !azblob_oldapi$" internal/upload/azure/page_blob_url_oldapi.go
# Add a build constraint to the wrappers of the new APIs
sed -i "s$// +build !kolo_xmlrpc_oldapi$// +build kolo_xmlrpc_oldapi$" internal/upload/koji/xmlrpc-response.go
sed -i "s$// +build !azblob_oldapi$// +build azblob_oldapi$" internal/upload/azure/page_blob_url.go
%endif
%if 0%{?fedora} >= 34
# Fedora 34 and newer ships a newer version of github.com/getkin/kin-openapi
# package which has a different API than the older ones. Let's make the auto-
@ -157,6 +144,7 @@ go test -c -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/osbuild-weldr-te
go test -c -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/osbuild-image-tests %{goipath}/cmd/osbuild-image-tests
go test -c -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/osbuild-auth-tests %{goipath}/cmd/osbuild-auth-tests
go test -c -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/osbuild-koji-tests %{goipath}/cmd/osbuild-koji-tests
go test -c -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/osbuild-composer-dbjobqueue-tests %{goipath}/cmd/osbuild-composer-dbjobqueue-tests
go build -tags=integration -ldflags="${TEST_LDFLAGS}" -o _bin/cloud-cleaner %{goipath}/cmd/cloud-cleaner
%endif
@ -190,10 +178,12 @@ install -m 0755 -vp _bin/osbuild-dnf-json-tests %{buildroot}%{_l
install -m 0755 -vp _bin/osbuild-image-tests %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp _bin/osbuild-auth-tests %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp _bin/osbuild-koji-tests %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp _bin/osbuild-composer-dbjobqueue-tests %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp _bin/cloud-cleaner %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/define-compose-url.sh %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/provision.sh %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/gen-certs.sh %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/gen-ssh.sh %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/image-info %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/run-koji-container.sh %{buildroot}%{_libexecdir}/osbuild-composer-test/
install -m 0755 -vp tools/koji-compose.py %{buildroot}%{_libexecdir}/osbuild-composer-test/
@ -235,6 +225,9 @@ install -m 0644 -vp test/data/koji/* %{buildroot}%{_d
install -m 0755 -vd %{buildroot}%{_datadir}/tests/osbuild-composer/x509
install -m 0644 -vp test/data/x509/* %{buildroot}%{_datadir}/tests/osbuild-composer/x509/
install -m 0755 -vd %{buildroot}%{_datadir}/tests/osbuild-composer/schemas
install -m 0644 -vp internal/jobqueue/dbjobqueue/schemas/* %{buildroot}%{_datadir}/tests/osbuild-composer/schemas/
%endif
%check
@ -283,8 +276,8 @@ The core osbuild-composer binary. This is suitable both for spawning in containe
Summary: The worker for osbuild-composer
Requires: systemd
Requires: qemu-img
Requires: osbuild >= 28
Requires: osbuild-ostree >= 28
Requires: osbuild >= 29
Requires: osbuild-ostree >= 29
# remove in F34
Obsoletes: golang-github-osbuild-composer-worker < %{version}-%{release}
@ -350,6 +343,7 @@ Requires: virt-install
Requires: expect
Requires: python3-lxml
Requires: httpd
Requires: mod_ssl
Requires: openssl
Requires: podman-plugins
Requires: dnf-plugins-core
@ -376,6 +370,9 @@ Integration tests to be run on a pristine-dedicated system to test the osbuild-c
%endif
%changelog
* Wed Aug 11 2021 Ondřej Budai <ondrej@budai.cz> - 31-1
- New upstream release
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 30-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (osbuild-composer-30.tar.gz) = 2b2f56d29b61a242edc1ef79502862dbb651e23ba9f717908793401352bd4cf0ec17229df4643e40a42cc4740506adf044fac05565d95d1e64e4c0aee1ae7be9
SHA512 (osbuild-composer-31.tar.gz) = 4a1acd5f131587f73c91f4185ec7c229ad47de613302aaf792916f49ead4643dcb58482b66a730e86b9040711fef589e2d113c7e21a72772cee4ca63e4bba276