diff options
Diffstat (limited to 'services/packages/debian/repository.go')
-rw-r--r-- | services/packages/debian/repository.go | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/services/packages/debian/repository.go b/services/packages/debian/repository.go index 46b1a94b81..25fa807351 100644 --- a/services/packages/debian/repository.go +++ b/services/packages/debian/repository.go @@ -32,8 +32,8 @@ import ( // GetOrCreateRepositoryVersion gets or creates the internal repository package // The Debian registry needs multiple index files which are stored in this package. -func GetOrCreateRepositoryVersion(ownerID int64) (*packages_model.PackageVersion, error) { - return packages_service.GetOrCreateInternalPackageVersion(ownerID, packages_model.TypeDebian, debian_module.RepositoryPackage, debian_module.RepositoryVersion) +func GetOrCreateRepositoryVersion(ctx context.Context, ownerID int64) (*packages_model.PackageVersion, error) { + return packages_service.GetOrCreateInternalPackageVersion(ctx, ownerID, packages_model.TypeDebian, debian_module.RepositoryPackage, debian_module.RepositoryVersion) } // GetOrCreateKeyPair gets or creates the PGP keys used to sign repository files @@ -98,7 +98,7 @@ func generateKeypair() (string, string, error) { // BuildAllRepositoryFiles (re)builds all repository files for every available distributions, components and architectures func BuildAllRepositoryFiles(ctx context.Context, ownerID int64) error { - pv, err := GetOrCreateRepositoryVersion(ownerID) + pv, err := GetOrCreateRepositoryVersion(ctx, ownerID) if err != nil { return err } @@ -147,7 +147,7 @@ func BuildAllRepositoryFiles(ctx context.Context, ownerID int64) error { // BuildSpecificRepositoryFiles builds index files for the repository func BuildSpecificRepositoryFiles(ctx context.Context, ownerID int64, distribution, component, architecture string) error { - pv, err := GetOrCreateRepositoryVersion(ownerID) + pv, err := GetOrCreateRepositoryVersion(ctx, ownerID) if err != nil { return err } @@ -234,6 +234,7 @@ func buildPackagesIndices(ctx context.Context, ownerID int64, repoVersion *packa {"Packages.xz", packagesXzContent}, } { _, err = packages_service.AddFileToPackageVersionInternal( + ctx, repoVersion, &packages_service.PackageFileCreationInfo{ PackageFileInfo: packages_service.PackageFileInfo{ @@ -381,6 +382,7 @@ func buildReleaseFiles(ctx context.Context, ownerID int64, repoVersion *packages {"InRelease", inReleaseContent}, } { _, err = packages_service.AddFileToPackageVersionInternal( + ctx, repoVersion, &packages_service.PackageFileCreationInfo{ PackageFileInfo: packages_service.PackageFileInfo{ |