Skip to content

Commit 8eeed23

Browse files
committed
Move benchmarks and src/MaxText to docker image
1 parent 4cf5bee commit 8eeed23

4 files changed

Lines changed: 6 additions & 12 deletions

File tree

.github/workflows/build_and_push_docker_image.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,6 @@ jobs:
123123
MODE=${{ inputs.build_mode }}
124124
WORKFLOW=${{ inputs.workflow }}
125125
PACKAGE_DIR=./src
126-
TESTS_DIR=./tests
127126
JAX_VERSION=NONE
128127
LIBTPU_VERSION=NONE
129128
INCLUDE_TEST_ASSETS=true

src/dependencies/dockerfiles/maxtext_gpu_dependencies.Dockerfile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,6 @@ ENV ENV_DEVICE=$DEVICE
4141
ARG PACKAGE_DIR
4242
ENV PACKAGE_DIR=$PACKAGE_DIR
4343

44-
ARG TESTS_DIR
45-
ENV TESTS_DIR=$TESTS_DIR
46-
4744
ENV MAXTEXT_ASSETS_ROOT=/deps/src/maxtext/assets
4845
ENV MAXTEXT_TEST_ASSETS_ROOT=/deps/tests/assets
4946
ENV MAXTEXT_PKG_DIR=/deps/src/maxtext
@@ -66,7 +63,9 @@ RUN --mount=type=cache,target=/root/.cache/uv \
6663

6764
# Now copy the remaining code (source files that may change frequently)
6865
COPY ${PACKAGE_DIR}/maxtext/ src/maxtext/
69-
COPY ${TESTS_DIR}*/ tests/
66+
COPY ${PACKAGE_DIR}/MaxText/ src/MaxText/
67+
COPY tests*/ tests/
68+
COPY benchmarks*/ benchmarks/
7069

7170
# Download test assets from GCS if building image with test assets
7271
ARG INCLUDE_TEST_ASSETS=false

src/dependencies/dockerfiles/maxtext_tpu_dependencies.Dockerfile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,6 @@ ENV ENV_DEVICE=$DEVICE
3838
ARG PACKAGE_DIR
3939
ENV PACKAGE_DIR=$PACKAGE_DIR
4040

41-
ARG TESTS_DIR
42-
ENV TESTS_DIR=$TESTS_DIR
43-
4441
ENV MAXTEXT_ASSETS_ROOT=/deps/src/maxtext/assets
4542
ENV MAXTEXT_TEST_ASSETS_ROOT=/deps/tests/assets
4643
ENV MAXTEXT_PKG_DIR=/deps/src/maxtext
@@ -66,7 +63,9 @@ RUN --mount=type=cache,target=/root/.cache/uv \
6663

6764
# Now copy the remaining code (source files that may change frequently)
6865
COPY ${PACKAGE_DIR}/maxtext/ src/maxtext/
69-
COPY ${TESTS_DIR}*/ tests/
66+
COPY ${PACKAGE_DIR}/MaxText/ src/MaxText/
67+
COPY tests*/ tests/
68+
COPY benchmarks*/ benchmarks/
7069

7170
# Download test assets from GCS if building image with test assets
7271
ARG INCLUDE_TEST_ASSETS=false

src/dependencies/scripts/docker_build_dependency_image.sh

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@
2222

2323
PACKAGE_DIR="${PACKAGE_DIR:-src}"
2424
echo "PACKAGE_DIR: $PACKAGE_DIR"
25-
TESTS_DIR="${TESTS_DIR:-tests}"
26-
echo "TESTS_DIR: $TESTS_DIR"
2725

2826
# Enable "exit immediately if any command fails" option
2927
set -e
@@ -73,7 +71,6 @@ docker_build_args=(
7371
"MODE=${MODE}"
7472
"JAX_VERSION=${JAX_VERSION}"
7573
"PACKAGE_DIR=${PACKAGE_DIR}"
76-
"TESTS_DIR=${TESTS_DIR}"
7774
)
7875

7976
run_docker_build() {

0 commit comments

Comments
 (0)