build-image: Try to create local debian repositories

For the local debian repositories have been configured beforehand
to apt, running 'build-image' before 'build-pkgs' triggers below issue:
Failed to fetch
http://stx-stx-repomgr:80/deb-local-build/dists/bullseye/main/binary-amd64/Packages
404 Not Found

Now tried to create an empty repository if it doesn't exist to avoid the
above issue.

Story: 2008846
Task: 43758

Signed-off-by: hbai <haiqing.bai@windriver.com>
Change-Id: Icf11c15bcbe6ba767d6058b02bfa35b8242fa32c
This commit is contained in:
hbai 2022-01-18 18:26:08 +08:00
parent f3ba3ca0f1
commit 0af79a43f5

View File

@ -207,6 +207,8 @@ if __name__ == "__main__":
repo_manager = repo_manage.RepoMgr('aptly', os.environ.get('REPOMGR_URL'),
'/tmp/', logger)
repo_manager.upload_pkg(REPO_BUILD, None)
repo_manager.upload_pkg(REPO_BINARY, None)
logger.info("\n")
logger.info("=====Build Image start ......")