Skip to content
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

NetworkRequirement is disable by default. #26

Open
mosoriob opened this issue May 11, 2021 · 0 comments
Open

NetworkRequirement is disable by default. #26

mosoriob opened this issue May 11, 2021 · 0 comments

Comments

@mosoriob
Copy link
Contributor

The container doesn't have a network by default.

This can be a problem for a notebook that needs to connect to an API, etc.

$ ➜  ~ cwltool main.cwl values.yml 
INFO /var/lib/mfosorio/.pyenv/versions/3.8.6/bin/cwltool 3.0.20200706173533
INFO Resolved 'main.cwl' to 'file:///var/lib/mfosorio/main.cwl'
INFO [job main.cwl] /tmp/kupk_eno$ docker \
    run \
    -i \
    --mount=type=bind,source=/tmp/kupk_eno,target=/flioxh \
    --mount=type=bind,source=/tmp/yd49s0sy,target=/tmp \
    --mount=type=bind,source=/tmp/tmpabomgfk0,target=/var/lib/cwl/stg30c91233-2f1a-4496-a669-8905d4964c59/model.tflite,readonly \
    --workdir=/flioxh \
    --read-only=true \
    --net=none \
    --user=10004:20163 \
    --rm \
    --env=TMPDIR=/tmp \
    --env=HOME=/flioxh \
    --cidfile=/tmp/h555rod9/20210511160016-960586.cid \
    r2d-2ftmp-2frepo2cwl-5fcr38hhip-2frepo1620766586 \
    /app/cwl/bin/main \
    -- \
    --cameraType \
    0 \
    --modelPath \
    /var/lib/cwl/stg30c91233-2f1a-4496-a669-8905d4964c59/model.tflite \
    --siteID \
    0

The solution is to add the NetworkAccess as requirements

requirements:
  NetworkAccess:
    networkAccess: true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant