Comments (4)
I don't fully remember how SELinux works (or doesn't), but if we were planning on targeting RedHat platforms in the future it might make sense to distribute a policy module along with it. @mathstuf might know more.
from girder_worker.
(Shot in the dark) The --volume
option being passed to docker is probably missing a :Z
option:
docker run -v /var/db:/var/db:Z rhel7 /bin/sh
from girder_worker.
Thanks @mathstuf , we indeed were not adding that option. Worth trying out to see if using that makes it work with SELinux enabled.
from girder_worker.
If I change the relevant part of plugins/docker/__init__.py
to add the :Z
option, the chmod
error disappears, but the input file still doesn't exist and now the output file cannot be found (perhaps in relation to the script not finishing because the input isn't found). It still runs clean when leaving out the --selinux-enabled
flag with :Z
option added.
@@ -87,7 +87,7 @@ def task_cleanup(e):
if e.info['task']['mode'] == 'docker' and '_tempdir' in e.info['kwargs']:
tmpdir = e.info['kwargs']['_tempdir']
cmd = [
- 'docker', 'run', '--rm', '-v', '%s:%s' % (tmpdir, DATA_VOLUME),
+ 'docker', 'run', '--rm', '-v', '%s:%s:Z' % (tmpdir, DATA_VOLUME),
'busybox', 'chmod', '-R', 'a+rw', DATA_VOLUME
]
p = subprocess.Popen(args=cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
INFO:root:Created LRU Cache for 'tilesource' with 1934 maximum size
WARNING:ctk_cli.module:'reference' attribute of 'file' is not part of the spec yet (CTK issue #623)
>> CLI Parameters ...
Namespace(analysis_mag=20.0, analysis_roi=[14175.0, 16923.0, 762.0, 771.0], analysis_tile_size=4096.0, foreground_threshold=60.0, inputImageFile='/mnt/girder_worker/data/TCGA-02-0010-01Z-00-DX4.07de2e55-a8fe-40ee-9e98-bcb78050b9f7.svs/TCGA-02-0010-01Z-00-DX4.07de2e55-a8fe-40ee-9e98-bcb78050b9f7.svs', local_max_search_radius=10.0, max_radius=30.0, min_fgnd_frac=0.5, min_nucleus_area=80.0, min_radius=20.0, outputNucleiAnnotationFile='/mnt/girder_worker/data/output2.anot', reference_mu_lab=[8.63234435, -0.11501964, 0.03868433], reference_std_lab=[0.57506023, 0.10403329, 0.01364062], scheduler_address='', stain_1='hematoxylin', stain_2='eosin', stain_3='null')
Traceback (most recent call last):
File "NucleiDetection/NucleiDetection.py", line 368, in <module>
main(CLIArgumentParser().parse_args())
File "NucleiDetection/NucleiDetection.py", line 182, in main
raise IOError('Input image file does not exist.')
IOError: Input image file does not exist.
Exception: Output filepath /home/neal/work/DSA-dev/tmp/tmpRJtayd/output2.anot does not exist.
File "/home/neal/work/DSA-dev/virtualenv/lib/python2.7/site-packages/celery/app/trace.py", line 367, in trace_task
R = retval = fun(*args, **kwargs)
File "/home/neal/work/DSA-dev/virtualenv/lib/python2.7/site-packages/celery/app/trace.py", line 622, in __protected_call__
return self.run(*args, **kwargs)
File "/home/neal/work/DSA-dev/girder_worker/girder_worker/tasks.py", line 17, in run
return core.run(*pargs, **kwargs)
File "/home/neal/work/DSA-dev/girder_worker/girder_worker/core/utils.py", line 122, in wrapped
return fn(*args, **kwargs)
File "/home/neal/work/DSA-dev/girder_worker/girder_worker/core/__init__.py", line 319, in run
auto_convert=auto_convert, validate=validate, **kwargs)
File "/home/neal/work/DSA-dev/girder_worker/girder_worker/plugins/docker/executor.py", line 207, in run
raise Exception('Output filepath %s does not exist.' % path)
from girder_worker.
Related Issues (20)
- Flesh out documentation section about Girder + Girder_Worker
- Document job_manager usage in tasks
- RFC: Consider cache configuration in new girder worker tasks HOT 2
- Girder worker integration test plugin is not compatible with girder 3.
- Create "How to write an integration test" documentation for girder worker
- spaces in girder folder name are incorrectly converted to container args. HOT 5
- Check if Celery Pinning is still necessary HOT 24
- Docker in docker permission issue HOT 1
- Girder Client 2.4.0 breaking integration test HOT 7
- girder_plugin settings for worker.api_url, worker.broker, worker.backend are not being picked up correctly HOT 3
- Using kwargs in chained tasks fails to create Job object
- Revoke integration tests are hanging HOT 1
- girder_result_hooks cleanup methods are not called after task is done
- File paths from docker transforms should be wrapped in quotes HOT 1
- Document job event binding and output reference kwargs. HOT 7
- Running NVidia dockers
- docker_run can't process non-string arguments HOT 3
- Exceptions are silently ignored during plugin load
- Girder plugin: use setting default HOT 1
- Pin celery version in requirements.in HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from girder_worker.