Skip to content
Snippets Groups Projects
Commit fdf441d9 authored by Lars Bilke's avatar Lars Bilke
Browse files

Added option --tag.

parent aac4aca2
No related branches found
No related tags found
No related merge requests found
...@@ -92,6 +92,11 @@ class Cli_Args(argparse.ArgumentParser): ...@@ -92,6 +92,11 @@ class Cli_Args(argparse.ArgumentParser):
default='registry.opengeosys.org/ogs/ogs', default='registry.opengeosys.org/ogs/ogs',
help='The docker registry the image is tagged and ' help='The docker registry the image is tagged and '
'uploaded to.') 'uploaded to.')
build_g.add_argument(
'--tag',
type=str,
default='',
help='The full docker image tag. Overwrites --registry.')
build_g.add_argument('--convert', build_g.add_argument('--convert',
'-C', '-C',
dest='convert', dest='convert',
......
...@@ -101,13 +101,13 @@ class container_info(): ...@@ -101,13 +101,13 @@ class container_info():
self.img_file += f'-cmake-{cmake_args_hash_short}' self.img_file += f'-cmake-{cmake_args_hash_short}'
if args.gui: if args.gui:
self.img_file += '-gui' self.img_file += '-gui'
if args.docs:
self.img_file += '-docs'
if ogs_version != 'off' and not args.runtime_only: if ogs_version != 'off' and not args.runtime_only:
self.img_file += '-dev' self.img_file += '-dev'
docker_repo = self.img_file
self.tag = f"{args.registry}/{docker_repo}:latest" if args.tag != '':
self.tag = args.tag
else:
self.tag = f"{args.registry}/{self.img_file}:latest"
if os.path.isdir(ogs_version): if os.path.isdir(ogs_version):
self.ogsdir = True self.ogsdir = True
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment