-
-
Notifications
You must be signed in to change notification settings - Fork 231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Override setting --user option for docker run #47
Override setting --user option for docker run #47
Conversation
…variable instead of the --user argument
👍 @tetron |
Unfortunately I don't want to add HOSTUSER=euid to the default environment without adding it to the CWL spec, which requires more discussion. It also requires some cooperation from tool running in the container and I'd prefer to avoid that. Another possible approach to dealing with file permissions is to use the set group id bit on the output directory. This should result in the files written to the output directory having the gid of the group of the host users, which means the host user should be able to manipulate the files after the container has finished. However I haven't tried it yet, but would probably accept an alternate pull request if you want to do it. |
Thank you @agduncan94 for your pull request. There has been a lot of changes to the spec and this implementation since March so I'm going to close this for now. You are very welcome to open an issue to discuss this further. |
7a9bee2 Add 'v1.1.0-dev1/salad/' from commit '98a5bea104672f9c652ad17ead5c6869a0da2cdf' 5853de0 refresh schema salad 762d534 update new draft documentation a33dd70 initial v1.1.0-dev1 2c85ac4 README update 3a5061d Add support for --junit-xml to run_test.sh d37ef31 Run tests with "cwltest" instead of "python -m cwltool.cwltest" cf28454 Add test for using initial work dir, docker, and secondary files. 98a5bea Update py3 setuptools pip wheel 8646e82 Run install-dep for py3 d866c53 pin ruamel py3 install 04dd72f Add ruamel.yaml to py3 jenkins testing. 56ddb9d Update requirements.txt again for CacheControl and lockfile. a5ac105 Update requirements.txt 5dff7db Add version constraint typing >= 3.5.2 so ruamel typechecks work. (#55) 6fb2969 Merge pull request #54 from common-workflow-language/newer-ruamel bc57aa0 adopt fixed ruamel.yaml 236b042 make mypy invocation py3 compat 61636e4 switch to latest ruamel.yaml with native types fefc957 install typed-ast during Jenkins tests c570b8a update to minimally required version of pip bada048 remove old setuptools wheel, then fix pip, then upgrade setuptools 454733c fix pip, then install setuptools a0c7d1a fix pip 9012e2b forcibly remove old setuptools 559f19a fix setuptools version specification typo 8a34425 update release test a833808 Merge pull request #52 from common-workflow-language/install-tests ac7341c last fix for the release test! 70dbadc also ship metaschema in source distribution ad0b913 add the Makefile to the source distribution 6df505c clarify module != package name 5890eb2 make tests installable and runnable after install 0514920 Merge pull request #51 from common-workflow-language/tighten-typecheck caa854a tweak travis/tox config b0c357b tighten up types ab9f395 Merge pull request #50 from common-workflow-language/type-docs 4ef0ed1 document how to expand Typeshed c646a62 Merge pull request #49 from common-workflow-language/schema-cache 14d51ca fix types 7dbffaf Add general http caching support. Applies to $import, $include and $schemas. f8297cc Cache external schemas after being loaded 1st time (doesn't cache to disk, though.) 2300cb0 Merge pull request #48 from common-workflow-language/fix-jsonld-context 449b5b8 Bump version c8305c0 Add default @id field to json-ld context if missing. ea983fd Merge pull request #47 from common-workflow-language/install-tests 7bd46e1 make tests installable and runnable after install 66b5ac6 update ruamel.yaml types 9e11a86 Merge pull request #46 from common-workflow-language/ruamel-yaml-bump 17fe62e re-pin ruamel.yaml fe7c49f Merge pull request #45 from common-workflow-language/improve-makerdf 3b414e7 replace variable shadowing with more meaningful names 1b1f58f replace Py3 exception passing to logger with py2 version b8ba072 update types 7008d94 Bugfix makerdf (helper function for converting to RDF). 94d9847 Merge pull request #44 from common-workflow-language/revert-optional-required 8a211bc Revert "make explicit optional and required fields" c9fc39f Name field is ambigous, so use list. f814cdb Can't distinguish between single SpecializeDef and mapSubject/mapPredicate, so disallow. 9f3927d update to v1.14 13061e5 Merge pull request #42 from common-workflow-language/specialize-refscope 750922d Can use refScope and mapSubject/mapPredicate on specialize. 9773208 Merge pull request #38 from common-workflow-language/mixin 5d1bda4 Merge pull request #40 from common-workflow-language/doc-map a6d6136 update type for typefmt() 41f414d Merge pull request #41 from common-workflow-language/rdfscomment c3ada96 update type for fetch() 2abc7f4 Doc generation understands mapSubject/mapPredicate -> map<> db8f409 sld:doc -> rdfs:comment aea5636 Add documentation about mixin. 63822d6 Remove spurious prints. 4217af8 Add mixin d626a74 Implement $mixin 93ed1fb pin ruamel.yaml to working version aa83430 Merge pull request #36 from common-workflow-language/explicit-optional a58b955 make explicit optional and required fields c509a07 Merge pull request #34 from common-workflow-language/unscoped_ids f857e9d type fixups 0407370 Allow idmaps for record fields. 5d9a08e Use makerdf for --print-rdf ce00252 Add test for non-scoped identifiers. ef27301 restore a dropped cast git-subtree-dir: cwltool/schemas git-subtree-split: 7a9bee2
7a9bee2 Add 'v1.1.0-dev1/salad/' from commit '98a5bea104672f9c652ad17ead5c6869a0da2cdf' 5853de0 refresh schema salad 762d534 update new draft documentation a33dd70 initial v1.1.0-dev1 2c85ac4 README update 3a5061d Add support for --junit-xml to run_test.sh d37ef31 Run tests with "cwltest" instead of "python -m cwltool.cwltest" cf28454 Add test for using initial work dir, docker, and secondary files. 98a5bea Update py3 setuptools pip wheel 8646e82 Run install-dep for py3 d866c53 pin ruamel py3 install 04dd72f Add ruamel.yaml to py3 jenkins testing. 56ddb9d Update requirements.txt again for CacheControl and lockfile. a5ac105 Update requirements.txt 5dff7db Add version constraint typing >= 3.5.2 so ruamel typechecks work. (#55) 6fb2969 Merge pull request #54 from common-workflow-language/newer-ruamel bc57aa0 adopt fixed ruamel.yaml 236b042 make mypy invocation py3 compat 61636e4 switch to latest ruamel.yaml with native types fefc957 install typed-ast during Jenkins tests c570b8a update to minimally required version of pip bada048 remove old setuptools wheel, then fix pip, then upgrade setuptools 454733c fix pip, then install setuptools a0c7d1a fix pip 9012e2b forcibly remove old setuptools 559f19a fix setuptools version specification typo 8a34425 update release test a833808 Merge pull request #52 from common-workflow-language/install-tests ac7341c last fix for the release test! 70dbadc also ship metaschema in source distribution ad0b913 add the Makefile to the source distribution 6df505c clarify module != package name 5890eb2 make tests installable and runnable after install 0514920 Merge pull request #51 from common-workflow-language/tighten-typecheck caa854a tweak travis/tox config b0c357b tighten up types ab9f395 Merge pull request #50 from common-workflow-language/type-docs 4ef0ed1 document how to expand Typeshed c646a62 Merge pull request #49 from common-workflow-language/schema-cache 14d51ca fix types 7dbffaf Add general http caching support. Applies to $import, $include and $schemas. f8297cc Cache external schemas after being loaded 1st time (doesn't cache to disk, though.) 2300cb0 Merge pull request #48 from common-workflow-language/fix-jsonld-context 449b5b8 Bump version c8305c0 Add default @id field to json-ld context if missing. ea983fd Merge pull request #47 from common-workflow-language/install-tests 7bd46e1 make tests installable and runnable after install 66b5ac6 update ruamel.yaml types 9e11a86 Merge pull request #46 from common-workflow-language/ruamel-yaml-bump 17fe62e re-pin ruamel.yaml fe7c49f Merge pull request #45 from common-workflow-language/improve-makerdf 3b414e7 replace variable shadowing with more meaningful names 1b1f58f replace Py3 exception passing to logger with py2 version b8ba072 update types 7008d94 Bugfix makerdf (helper function for converting to RDF). 94d9847 Merge pull request #44 from common-workflow-language/revert-optional-required 8a211bc Revert "make explicit optional and required fields" c9fc39f Name field is ambigous, so use list. f814cdb Can't distinguish between single SpecializeDef and mapSubject/mapPredicate, so disallow. 9f3927d update to v1.14 13061e5 Merge pull request #42 from common-workflow-language/specialize-refscope 750922d Can use refScope and mapSubject/mapPredicate on specialize. 9773208 Merge pull request #38 from common-workflow-language/mixin 5d1bda4 Merge pull request #40 from common-workflow-language/doc-map a6d6136 update type for typefmt() 41f414d Merge pull request #41 from common-workflow-language/rdfscomment c3ada96 update type for fetch() 2abc7f4 Doc generation understands mapSubject/mapPredicate -> map<> db8f409 sld:doc -> rdfs:comment aea5636 Add documentation about mixin. 63822d6 Remove spurious prints. 4217af8 Add mixin d626a74 Implement $mixin 93ed1fb pin ruamel.yaml to working version aa83430 Merge pull request #36 from common-workflow-language/explicit-optional a58b955 make explicit optional and required fields c509a07 Merge pull request #34 from common-workflow-language/unscoped_ids f857e9d type fixups 0407370 Allow idmaps for record fields. 5d9a08e Use makerdf for --print-rdf ce00252 Add test for non-scoped identifiers. ef27301 restore a dropped cast git-subtree-dir: cwltool/schemas git-subtree-split: 7a9bee2
7a9bee2 Add 'v1.1.0-dev1/salad/' from commit '98a5bea104672f9c652ad17ead5c6869a0da2cdf' 5853de0 refresh schema salad 762d534 update new draft documentation a33dd70 initial v1.1.0-dev1 2c85ac4 README update 3a5061d Add support for --junit-xml to run_test.sh d37ef31 Run tests with "cwltest" instead of "python -m cwltool.cwltest" cf28454 Add test for using initial work dir, docker, and secondary files. 98a5bea Update py3 setuptools pip wheel 8646e82 Run install-dep for py3 d866c53 pin ruamel py3 install 04dd72f Add ruamel.yaml to py3 jenkins testing. 56ddb9d Update requirements.txt again for CacheControl and lockfile. a5ac105 Update requirements.txt 5dff7db Add version constraint typing >= 3.5.2 so ruamel typechecks work. (#55) 6fb2969 Merge pull request #54 from common-workflow-language/newer-ruamel bc57aa0 adopt fixed ruamel.yaml 236b042 make mypy invocation py3 compat 61636e4 switch to latest ruamel.yaml with native types fefc957 install typed-ast during Jenkins tests c570b8a update to minimally required version of pip bada048 remove old setuptools wheel, then fix pip, then upgrade setuptools 454733c fix pip, then install setuptools a0c7d1a fix pip 9012e2b forcibly remove old setuptools 559f19a fix setuptools version specification typo 8a34425 update release test a833808 Merge pull request #52 from common-workflow-language/install-tests ac7341c last fix for the release test! 70dbadc also ship metaschema in source distribution ad0b913 add the Makefile to the source distribution 6df505c clarify module != package name 5890eb2 make tests installable and runnable after install 0514920 Merge pull request #51 from common-workflow-language/tighten-typecheck caa854a tweak travis/tox config b0c357b tighten up types ab9f395 Merge pull request #50 from common-workflow-language/type-docs 4ef0ed1 document how to expand Typeshed c646a62 Merge pull request #49 from common-workflow-language/schema-cache 14d51ca fix types 7dbffaf Add general http caching support. Applies to $import, $include and $schemas. f8297cc Cache external schemas after being loaded 1st time (doesn't cache to disk, though.) 2300cb0 Merge pull request #48 from common-workflow-language/fix-jsonld-context 449b5b8 Bump version c8305c0 Add default @id field to json-ld context if missing. ea983fd Merge pull request #47 from common-workflow-language/install-tests 7bd46e1 make tests installable and runnable after install 66b5ac6 update ruamel.yaml types 9e11a86 Merge pull request #46 from common-workflow-language/ruamel-yaml-bump 17fe62e re-pin ruamel.yaml fe7c49f Merge pull request #45 from common-workflow-language/improve-makerdf 3b414e7 replace variable shadowing with more meaningful names 1b1f58f replace Py3 exception passing to logger with py2 version b8ba072 update types 7008d94 Bugfix makerdf (helper function for converting to RDF). 94d9847 Merge pull request #44 from common-workflow-language/revert-optional-required 8a211bc Revert "make explicit optional and required fields" c9fc39f Name field is ambigous, so use list. f814cdb Can't distinguish between single SpecializeDef and mapSubject/mapPredicate, so disallow. 9f3927d update to v1.14 13061e5 Merge pull request #42 from common-workflow-language/specialize-refscope 750922d Can use refScope and mapSubject/mapPredicate on specialize. 9773208 Merge pull request #38 from common-workflow-language/mixin 5d1bda4 Merge pull request #40 from common-workflow-language/doc-map a6d6136 update type for typefmt() 41f414d Merge pull request #41 from common-workflow-language/rdfscomment c3ada96 update type for fetch() 2abc7f4 Doc generation understands mapSubject/mapPredicate -> map<> db8f409 sld:doc -> rdfs:comment aea5636 Add documentation about mixin. 63822d6 Remove spurious prints. 4217af8 Add mixin d626a74 Implement $mixin 93ed1fb pin ruamel.yaml to working version aa83430 Merge pull request #36 from common-workflow-language/explicit-optional a58b955 make explicit optional and required fields c509a07 Merge pull request #34 from common-workflow-language/unscoped_ids f857e9d type fixups 0407370 Allow idmaps for record fields. 5d9a08e Use makerdf for --print-rdf ce00252 Add test for non-scoped identifiers. ef27301 restore a dropped cast git-subtree-dir: cwltool/schemas git-subtree-split: 7a9bee2
7a9bee2 Add 'v1.1.0-dev1/salad/' from commit '98a5bea104672f9c652ad17ead5c6869a0da2cdf' 5853de0 refresh schema salad 762d534 update new draft documentation a33dd70 initial v1.1.0-dev1 2c85ac4 README update 3a5061d Add support for --junit-xml to run_test.sh d37ef31 Run tests with "cwltest" instead of "python -m cwltool.cwltest" cf28454 Add test for using initial work dir, docker, and secondary files. 98a5bea Update py3 setuptools pip wheel 8646e82 Run install-dep for py3 d866c53 pin ruamel py3 install 04dd72f Add ruamel.yaml to py3 jenkins testing. 56ddb9d Update requirements.txt again for CacheControl and lockfile. a5ac105 Update requirements.txt 5dff7db Add version constraint typing >= 3.5.2 so ruamel typechecks work. (#55) 6fb2969 Merge pull request #54 from common-workflow-language/newer-ruamel bc57aa0 adopt fixed ruamel.yaml 236b042 make mypy invocation py3 compat 61636e4 switch to latest ruamel.yaml with native types fefc957 install typed-ast during Jenkins tests c570b8a update to minimally required version of pip bada048 remove old setuptools wheel, then fix pip, then upgrade setuptools 454733c fix pip, then install setuptools a0c7d1a fix pip 9012e2b forcibly remove old setuptools 559f19a fix setuptools version specification typo 8a34425 update release test a833808 Merge pull request #52 from common-workflow-language/install-tests ac7341c last fix for the release test! 70dbadc also ship metaschema in source distribution ad0b913 add the Makefile to the source distribution 6df505c clarify module != package name 5890eb2 make tests installable and runnable after install 0514920 Merge pull request #51 from common-workflow-language/tighten-typecheck caa854a tweak travis/tox config b0c357b tighten up types ab9f395 Merge pull request #50 from common-workflow-language/type-docs 4ef0ed1 document how to expand Typeshed c646a62 Merge pull request #49 from common-workflow-language/schema-cache 14d51ca fix types 7dbffaf Add general http caching support. Applies to $import, $include and $schemas. f8297cc Cache external schemas after being loaded 1st time (doesn't cache to disk, though.) 2300cb0 Merge pull request #48 from common-workflow-language/fix-jsonld-context 449b5b8 Bump version c8305c0 Add default @id field to json-ld context if missing. ea983fd Merge pull request #47 from common-workflow-language/install-tests 7bd46e1 make tests installable and runnable after install 66b5ac6 update ruamel.yaml types 9e11a86 Merge pull request #46 from common-workflow-language/ruamel-yaml-bump 17fe62e re-pin ruamel.yaml fe7c49f Merge pull request #45 from common-workflow-language/improve-makerdf 3b414e7 replace variable shadowing with more meaningful names 1b1f58f replace Py3 exception passing to logger with py2 version b8ba072 update types 7008d94 Bugfix makerdf (helper function for converting to RDF). 94d9847 Merge pull request #44 from common-workflow-language/revert-optional-required 8a211bc Revert "make explicit optional and required fields" c9fc39f Name field is ambigous, so use list. f814cdb Can't distinguish between single SpecializeDef and mapSubject/mapPredicate, so disallow. 9f3927d update to v1.14 13061e5 Merge pull request #42 from common-workflow-language/specialize-refscope 750922d Can use refScope and mapSubject/mapPredicate on specialize. 9773208 Merge pull request #38 from common-workflow-language/mixin 5d1bda4 Merge pull request #40 from common-workflow-language/doc-map a6d6136 update type for typefmt() 41f414d Merge pull request #41 from common-workflow-language/rdfscomment c3ada96 update type for fetch() 2abc7f4 Doc generation understands mapSubject/mapPredicate -> map<> db8f409 sld:doc -> rdfs:comment aea5636 Add documentation about mixin. 63822d6 Remove spurious prints. 4217af8 Add mixin d626a74 Implement $mixin 93ed1fb pin ruamel.yaml to working version aa83430 Merge pull request #36 from common-workflow-language/explicit-optional a58b955 make explicit optional and required fields c509a07 Merge pull request #34 from common-workflow-language/unscoped_ids f857e9d type fixups 0407370 Allow idmaps for record fields. 5d9a08e Use makerdf for --print-rdf ce00252 Add test for non-scoped identifiers. ef27301 restore a dropped cast git-subtree-dir: cwltool/schemas git-subtree-split: 7a9bee2
make tests installable and runnable after install
The flag --no-user will stop cwltools from passing --user euid to docker run and will instead pass the environment variable HOSTUSER=euid.
This is to deal with situations where the EUID of the host does not match the EUID of the user in the container (or the EUID of the host does not exist in the container). Such a situation could cause unexpected issues with running the container. Instead what creators of the containers can do is chown the output directory to the given HOSTUSER environment variable (if needed). This deals with the assumption that the container can be run as the user with EUID the same as the host and that the user with the given EUID exists.