-
Notifications
You must be signed in to change notification settings - Fork 3
[CI] Enable devcontainer jobs #82
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
Merged
+303
−17
Merged
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,61 @@ | ||
| # syntax=docker/dockerfile:1.5 | ||
|
|
||
| ARG BASE | ||
| ARG PYTHON_PACKAGE_MANAGER=conda | ||
|
|
||
| FROM ${BASE} as pip-base | ||
|
|
||
| ENV DEFAULT_VIRTUAL_ENV=rapids | ||
| ENV RAPIDS_LIBUCX_PREFER_SYSTEM_LIBRARY=true | ||
|
|
||
| RUN apt update -y \ | ||
| && DEBIAN_FRONTEND=noninteractive apt install -y \ | ||
| libblas-dev liblapack-dev \ | ||
| && rm -rf /tmp/* /var/tmp/* /var/cache/apt/* /var/lib/apt/lists/*; | ||
|
|
||
| FROM ${BASE} as conda-base | ||
|
|
||
| ENV DEFAULT_CONDA_ENV=rapids | ||
|
|
||
| FROM ${PYTHON_PACKAGE_MANAGER}-base | ||
|
|
||
| ARG TARGETARCH | ||
|
|
||
| ARG CUDA | ||
| ENV CUDAARCHS="RAPIDS" | ||
| ENV CUDA_VERSION="${CUDA_VERSION:-${CUDA}}" | ||
|
|
||
| ARG PYTHON_PACKAGE_MANAGER | ||
| ENV PYTHON_PACKAGE_MANAGER="${PYTHON_PACKAGE_MANAGER}" | ||
|
|
||
| ENV PYTHONSAFEPATH="1" | ||
| ENV PYTHONUNBUFFERED="1" | ||
| ENV PYTHONDONTWRITEBYTECODE="1" | ||
|
|
||
| ENV HISTFILE="/home/coder/.cache/._bash_history" | ||
|
|
||
| ### | ||
| # sccache configuration | ||
| ### | ||
| ENV AWS_ROLE_ARN="arn:aws:iam::279114543810:role/nv-gha-token-sccache-devs" | ||
| ENV SCCACHE_REGION="us-east-2" | ||
| ENV SCCACHE_BUCKET="rapids-sccache-devs" | ||
| ENV SCCACHE_S3_USE_PREPROCESSOR_CACHE_MODE=true | ||
| ENV SCCACHE_IDLE_TIMEOUT=0 | ||
|
|
||
| ### | ||
| # sccache-dist configuration | ||
| ### | ||
| # Enable sccache-dist by default | ||
| ENV DEVCONTAINER_UTILS_ENABLE_SCCACHE_DIST=1 | ||
| # Compile locally if max retries exceeded | ||
| ENV SCCACHE_DIST_FALLBACK_TO_LOCAL_COMPILE=true | ||
| # Retry transient errors 4 times (for a total of 5 attempts) | ||
| ENV SCCACHE_DIST_MAX_RETRIES=4 | ||
| # 1hr 59min (to accommodate debug builds) | ||
| ENV SCCACHE_DIST_REQUEST_TIMEOUT=7140 | ||
| ENV SCCACHE_DIST_URL="https://${TARGETARCH}.linux.sccache.rapids.nvidia.com" | ||
|
|
||
| # Build as much in parallel as possible | ||
| ENV INFER_NUM_DEVICE_ARCHITECTURES=1 | ||
| ENV MAX_DEVICE_OBJ_TO_COMPILE_IN_PARALLEL=20 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,35 @@ | ||
| # nvForest Development Containers | ||
|
|
||
| This directory contains [devcontainer configurations](https://containers.dev/implementors/json_reference/) for using VSCode to [develop in a container](https://code.visualstudio.com/docs/devcontainers/containers) via the `Remote Containers` [extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) or [GitHub Codespaces](https://github.com/codespaces). | ||
|
|
||
| This container is a turnkey development environment for building and testing the nvForest C++ and Python libraries. | ||
|
|
||
| ## Table of Contents | ||
|
|
||
| * [Prerequisites](#prerequisites) | ||
| * [Host bind mounts](#host-bind-mounts) | ||
| * [Launch a Dev Container](#launch-a-dev-container) | ||
|
|
||
| ## Prerequisites | ||
|
|
||
| * [VSCode](https://code.visualstudio.com/download) | ||
| * [VSCode Remote Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) | ||
|
|
||
| ## Host bind mounts | ||
|
|
||
| By default, the following directories are bind-mounted into the devcontainer: | ||
|
|
||
| * `${repo}:/home/coder/nvforest` | ||
| * `${repo}/../.aws:/home/coder/.aws` | ||
| * `${repo}/../.local:/home/coder/.local` | ||
| * `${repo}/../.cache:/home/coder/.cache` | ||
| * `${repo}/../.conda:/home/coder/.conda` | ||
| * `${repo}/../.config:/home/coder/.config` | ||
|
|
||
| This ensures caches, configurations, dependencies, and your commits are persisted on the host across container runs. | ||
|
|
||
| ## Launch a Dev Container | ||
|
|
||
| To launch a devcontainer from VSCode, open the nvForest repo and select the "Reopen in Container" button in the bottom right:<br/><img src="https://user-images.githubusercontent.com/178183/221771999-97ab29d5-e718-4e5f-b32f-2cdd51bba25c.png"/> | ||
|
|
||
| Alternatively, open the VSCode command palette (typically `cmd/ctrl + shift + P`) and run the "Rebuild and Reopen in Container" command. | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add alt text to the image for accessibility.
The image tag is missing alternative text, which is required for accessibility compliance. Static analysis flagged this as MD045 (no-alt-text).
📝 Proposed fix
📝 Committable suggestion
🧰 Tools
🪛 markdownlint-cli2 (0.21.0)
[warning] 33-33: Images should have alternate text (alt text)
(MD045, no-alt-text)
🤖 Prompt for AI Agents