Skip to content

Commit

Permalink
Do not ignore node_modules
Browse files Browse the repository at this point in the history
Signed-off-by: prabhu <prabhu@appthreat.com>

nydus test

Signed-off-by: Prabhu Subramanian <prabhu@appthreat.com>
  • Loading branch information
prabhu committed Nov 21, 2023
1 parent fa40e3c commit 5454fb8
Show file tree
Hide file tree
Showing 4 changed files with 95 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/java-reachables-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- name: compile
run: |
cd repotests/dependency-track
mvn clean compile -DskipTests -Dmaven.test.skip=true
mvn -q clean compile -DskipTests -Dmaven.test.skip=true
- name: repotests
run: |
bin/cdxgen.js -p -t java --profile research -o repotests/dependency-track/bom.json repotests/dependency-track
Expand Down
60 changes: 60 additions & 0 deletions .github/workflows/nydus-demo.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: nydus tests

on:
pull_request:
workflow_dispatch:
jobs:
build:
strategy:
fail-fast: false
matrix:
node-version: ['21.x']
os: ['ubuntu-latest']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '19'
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- uses: actions/checkout@v4
with:
repository: 'DependencyTrack/dependency-track'
path: 'repotests/dependency-track'
- name: setup nydus
run: |
curl -LO https://github.com/dragonflyoss/nydus/releases/download/v2.2.4/nydus-static-v2.2.4-linux-amd64.tgz
tar -xvf nydus-static-v2.2.4-linux-amd64.tgz
chmod +x nydus-static/*
mv nydus-static/* /usr/local/bin/
rm -rf nydus-static-v2.2.4-linux-amd64.tgz nydus-static
curl -LO https://github.com/containerd/nerdctl/releases/download/v1.7.0/nerdctl-full-1.7.0-linux-amd64.tar.gz
sudo tar Cxzvf /usr/local nerdctl-full-1.7.0-linux-amd64.tar.gz
sudo mkdir -p /etc/nydus/
sudo rm -rf /var/lib/containerd-nydus
curl -LO https://github.com/containerd/nydus-snapshotter/releases/download/v0.13.3/nydus-snapshotter-v0.13.3-x86_64.tgz
sudo tar Cxzvf /usr/local/bin nydus-snapshotter-v0.13.3-x86_64.tgz
sudo mv /usr/local/bin/nydus-snapshotter/* /usr/local/bin/
sudo cp ./ci/nydusd-config.fusedev.json /etc/nydus/nydusd-config.fusedev.json
sudo mkdir -p /etc/containerd
sudo cp ./ci/containerd-config.toml /etc/containerd/config.toml
sudo systemctl enable --now containerd
sudo systemctl restart containerd
- name: compile
run: |
cd repotests/dependency-track
mvn -q clean compile -DskipTests -Dmaven.test.skip=true
- name: repotests
run: |
sudo /usr/local/bin/containerd-nydus-grpc --nydusd-config /etc/nydus/nydusd-config.fusedev.json &
sleep 30
cd repotests/dependency-track
sudo nerdctl --snapshotter nydus run --rm -e CDXGEN_DEBUG_MODE -v $HOME/.m2:/root/.m2 -v $(pwd):/app ghcr.io/cyclonedx/cdxgen:master-nydus -p --profile research -t java /app
ls -ltr
env:
CDXGEN_DEBUG_MODE: debug
4 changes: 4 additions & 0 deletions ci/containerd-config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[proxy_plugins]
[proxy_plugins.nydus]
type = "snapshot"
address = "/run/containerd-nydus/containerd-nydus-grpc.sock"
30 changes: 30 additions & 0 deletions ci/nydusd-config.fusedev.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
{
"device": {
"backend": {
"type": "registry",
"config": {
"scheme": "",
"skip_verify": true,
"timeout": 5,
"connect_timeout": 5,
"retry_limit": 4,
"auth": ""
}
},
"cache": {
"type": "blobcache",
"config": {
"work_dir": "cache"
}
}
},
"mode": "direct",
"digest_validate": false,
"iostats_files": false,
"enable_xattr": true,
"fs_prefetch": {
"enable": true,
"threads_count": 4
}
}

0 comments on commit 5454fb8

Please # to comment.