aboutsummaryrefslogtreecommitdiffstats
path: root/vnfsdk_pkgtools
diff options
context:
space:
mode:
Diffstat (limited to 'vnfsdk_pkgtools')
-rw-r--r--vnfsdk_pkgtools/packager/csar.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/vnfsdk_pkgtools/packager/csar.py b/vnfsdk_pkgtools/packager/csar.py
index 8b1eb34..af84974 100644
--- a/vnfsdk_pkgtools/packager/csar.py
+++ b/vnfsdk_pkgtools/packager/csar.py
@@ -98,6 +98,8 @@ def write(source, entry, destination, args):
metadata[META_ENTRY_MANIFEST_FILE_KEY] = args.manifest
manifest_file = manifest.Manifest(source, args.manifest)
manifest_file_full_path = os.path.join(source, args.manifest)
+ elif args.certificate or args.digest:
+ raise ValueError("Must specify manifest file if certificate or digest is specified")
else:
manifest_file = None
manifest_file_full_path = None
@@ -117,7 +119,7 @@ def write(source, entry, destination, args):
check_dir=False)
metadata[META_ENTRY_CERT_FILE_KEY] = args.certificate
if not args.privkey:
- raise RuntimeError('Need private key file for signing')
+ raise ValueError('Need private key file for signing')
check_file_dir(root='',
entry=args.privkey,
msg='Please specify a valid private key file.',
@@ -334,8 +336,6 @@ class _CSARReader(object):
no_verify_cert)
os.unlink(tmp_manifest)
-
-
def _download(self, url, target):
response = requests.get(url, stream=True)
if response.status_code != 200: