77
88from .. import __version__
99from ..config import ALLOWED_IMAGE_REGEXPS
10- from ..config import ALLOWED_PUBLISH_PORTS_ALL
1110from ..config import CAPS_ADD
1211from ..config import CAPS_DROP
1312from ..config import ENV_VARS
1413from ..config import ENV_VARS_EXT
1514from ..config import NV_ALLOWED_GPUS
1615from ..config import NV_DEFAULT_GPU_COUNT_RESERVATION
1716from ..config import NV_MAX_GPU_COUNT_RESERVATION
18- from ..config import PRIVILEGED
1917from ..config import PROBE_USED_MOUNTS
2018from ..config import RUN_PULL
2119from ..config import USER_IN_CONTAINER
@@ -52,13 +50,6 @@ def parser_run(parser):
5250 default = [],
5351 )
5452
55- if ALLOWED_PUBLISH_PORTS_ALL :
56- sub_parser .add_argument (
57- "-P" , "--publish-all" ,
58- help = "Publish all exposed ports to random ports" ,
59- action = "store_true" ,
60- )
61-
6253 sub_parser .add_argument (
6354 "--entrypoint" ,
6455 help = "Overwrite the default ENTRYPOINT of the image" ,
@@ -207,8 +198,6 @@ def exec_cmd_run(args):
207198 for mount in mounts :
208199 cmd += ["-v" , mount ]
209200
210- if args .publish_all :
211- cmd += ["-P" ]
212201
213202 if args .executor == 'nvidia-docker' :
214203 prepare_nvidia_docker_run (args )
@@ -230,8 +219,6 @@ def exec_cmd_run(args):
230219 cmd += ["--cap-drop=%s" % cap_drop ]
231220 for cap_add in CAPS_ADD :
232221 cmd += ["--cap-add=%s" % cap_add ]
233- if PRIVILEGED :
234- cmd += ["--privileged" ]
235222
236223 if args .workdir :
237224 cmd += ["-w" , args .workdir ]
0 commit comments