diff --git a/.github/workflows/pr-build.yml b/.github/workflows/pr-build.yml new file mode 100644 index 0000000..91561ab --- /dev/null +++ b/.github/workflows/pr-build.yml @@ -0,0 +1,33 @@ +name: PR-Build + +run-name: PR Build Image + +on: + pull_request: + branches: ['main'] + +jobs: + pr-build: + # https://github.com/actions/runner-images + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + with: + platforms: arm64,amd64 + - name: Set up Docker Buildx + id: buildx + uses: docker/setup-buildx-action@v3 + + - name: Available platforms + run: echo ${{ steps.buildx.outputs.platforms }} + + - name: Run Buildx + run: | + docker buildx build \ + --platform linux/amd64,linux/arm64 \ + --output "type=image,push=false" \ + --file ./Dockerfile . \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 17d1910..db4a5ac 100644 --- a/Dockerfile +++ b/Dockerfile @@ -39,4 +39,7 @@ RUN apk add --no-cache --update \ bind-tools \ busybox-extras \ lz4 zstd \ - vim + vim \ + openssl \ + ipset \ + ripgrep diff --git a/README.md b/README.md index 8758ce2..9d45aa4 100644 --- a/README.md +++ b/README.md @@ -59,4 +59,19 @@ kubectl exec -it nettools -n default bash ```sh docker run -it ghcr.io/duyhenryer/nettools:2.0.1 sh +``` + +#### Sample Use-cases + +`tcpdump` is a powerful and common packet analyzer that runs under the command line. +It allows the user to display TCP/IP and other packets being transmitted or received over an attached network interface. + +```sh +tcpdump -i eth0 port 9999 -c 1 -Xvv +``` +More info on tcpdump can be found [here](http://www.tcpdump.org/tcpdump_man.html). + +`netstat` is a useful tool for checking your network configuration and activity. +```sh +netstat -tulpn ``` \ No newline at end of file