@tduncan / Nvidia-Optimization-Stack-VLLM Mirror · read-only / commits / 03dd7d52bf
Fork 0

A high-throughput and memory-efficient inference and serving engine for LLMs

Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git

Synced Nov 17, 01:45 UTC

[CI] clean docker cache for neuron (#4441)

Simon Mo committed Apr 28, 2024 at 16:32 UTC 03dd7d52bfcc4f21ba964a0cfc3fb6e7a47fb242
1 file changed +14
.buildkite/run-neuron-test.sh
+14
@@ -4,6 +4,20 @@ set -e
4
5 # Try building the docker image
6 aws ecr get-login-password --region us-west-2 | docker login --username AWS --password-stdin 763104351884.dkr.ecr.us-west-2.amazonaws.com
7 +
8 +# prune old image and containers to save disk space, and only once a day
9 +# by using a timestamp file in tmp.
10 +if [ -f /tmp/neuron-docker-build-timestamp ]; then
11 + last_build=$(cat /tmp/neuron-docker-build-timestamp)
12 + current_time=$(date +%s)
13 + if [ $((current_time - last_build)) -gt 86400 ]; then
14 + docker system prune -f
15 + echo $current_time > /tmp/neuron-docker-build-timestamp
16 + fi
17 +else
18 + echo $(date +%s) > /tmp/neuron-docker-build-timestamp
19 +fi
20 +
21 docker build -t neuron -f Dockerfile.neuron .
22
23 # Setup cleanup