SyneRBI / SIRF-Exercises

SIRF Training and demonstration material
http://www.ccpsynerbi.ac.uk
Apache License 2.0
17 stars 21 forks source link

Add .devcontainer and environment.yml #200

Closed KrisThielemans closed 1 year ago

KrisThielemans commented 1 year ago

This could work, but I cannot test it locally at the moment.

In GitHub Codespaces, I think I'm running out of quota (although my profile doesn't say that)


=================================================================================
2023-01-29 03:05:44.263Z: Configuration starting...
2023-01-29 03:05:44.302Z: Cloning...
2023-01-29 03:05:44.335Z: $ git -C "/var/lib/docker/codespacemount/workspace" clone --branch devcontainer --depth 1 https://github.com/SyneRBI/SIRF-Exercises "/var/lib/docker/codespacemount/workspace/SIRF-Exercises"
2023-01-29 03:05:44.357Z: Cloning into '/var/lib/docker/codespacemount/workspace/SIRF-Exercises'...
2023-01-29 03:05:45.951Z: git process exited with exit code 0
2023-01-29 03:05:45.958Z: $ git -C "/var/lib/docker/codespacemount/workspace/SIRF-Exercises" config --local remote.origin.fetch +refs/heads/*:refs/remotes/origin/*
2023-01-29 03:05:45.971Z: git process exited with exit code 0

=================================================================================
2023-01-29 03:05:46.381Z: Creating container...
2023-01-29 03:05:46.386Z: $ devcontainer up --id-label Type=codespaces --workspace-folder /var/lib/docker/codespacemount/workspace/SIRF-Exercises --mount type=bind,source=/.codespaces/agent/mount/cache,target=/vscode --user-data-folder /var/lib/docker/codespacemount/.persistedshare --container-data-folder .vscode-remote/data/Machine --container-system-data-folder /var/vscode-remote --log-level trace --log-format json --update-remote-user-uid-default never --mount-workspace-git-root false --skip-non-blocking-commands --skip-post-create --config "/var/lib/docker/codespacemount/workspace/SIRF-Exercises/.devcontainer/devcontainer.json" --override-config /root/.codespaces/shared/merged_devcontainer.json --default-user-env-probe loginInteractiveShell --container-session-data-folder /workspaces/.codespaces/.persistedshare/devcontainers-cli/cache
2023-01-29 03:05:46.592Z: @devcontainers/cli 0.28.0. Node.js v14.21.2. linux 5.4.0-1100-azure x64.
2023-01-29 03:05:50.277Z: $ docker buildx build --load --build-arg BUILDKIT_INLINE_CACHE=1 -f /tmp/devcontainercli-root/container-features/0.28.0-1674961550236/Dockerfile-with-features -t vsc-sirf-exercises-21beb555f10f2af844bfe4bc7a170126 --target dev_containers_target_stage --build-arg _DEV_CONTAINERS_BASE_IMAGE=dev_container_auto_added_stage_label /var/lib/docker/codespacemount/workspace/SIRF-Exercises
2023-01-29 03:05:50.852Z: #1 [internal] load .dockerignore

<lots of stuff>

2023-01-29 03:08:48.096Z: #6 extracting sha256:88aac493923a537b93e5f6a7b98dd8d039732b09540532846e97165a9e78b008 41.0s
2023-01-29 03:08:50.899Z: #6 ERROR: failed to register layer: ApplyLayer exit status 1 stdout:  stderr: write /opt/SIRF-SuperBuild/sources/STIR/.git/objects/pack/pack-533e3cc9c31914b44fce2b84517557b78da90d7f.pack: no space left on device
2023-01-29 03:08:50.984Z: ------
 > [dev_container_auto_added_stage_label 1/3] FROM docker.io/synerbi/sirf:devel@sha256:6e8bd754994cfcdd1a9b0d0b06ed9ce0c5d2203f52c5b2c611bd4f90ba6cee4a:

Probably best to reduce our docker image size in any case.

Full log: codespace.log

KrisThielemans commented 1 year ago

@paskino @samdporter @Imraj-Singh could you give this a go in VS Code?

KrisThielemans commented 1 year ago

I've created https://github.com/orgs/community/discussions/50403 in the hope somebody knows what to do. Still hoping that someone can try this branch in a local VS Code devcontainer. Maybe @gfardell can?

KrisThielemans commented 1 year ago

The above creation problem was resolved by requiring a 64gb codespace.

This is working now, but could likely be improved. feedback welcome

KrisThielemans commented 1 year ago

Ready. @paskino, want to have a quick look before merging?

Imraj-Singh commented 1 year ago

@KrisThielemans, I made a pull request to this branch, #207. Not sure if it's best to continue discussions here or on that new pull request?