Skip to content

Commit f682a85

Browse files
authored
Merge pull request #37619 from apache/playground-interactive
Add Apache Beam installation to Beam Playground Container Dockerfile
2 parents 298f309 + 08af69c commit f682a85

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

playground/backend/containers/python/Dockerfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,16 @@ RUN cd /opt/playground/backend/kafka-emulator/ && tar -xvf kafka-emulator.tar &&
6565
mv kafka-emulator/*.jar . && rmdir kafka-emulator/ &&\
6666
mv beam-playground-kafka-emulator-*.jar beam-playground-kafka-emulator.jar
6767
RUN apt-get update && \
68-
apt install openjdk-17-jre-headless -y
68+
apt install openjdk-17-jre-headless -y
6969

7070
# Create a user group `appgroup` and a user `appuser`
7171
RUN groupadd --gid 20000 appgroup \
7272
&& useradd --uid 20000 --gid appgroup --shell /bin/bash --create-home appuser
7373

7474
RUN mkdir -p /opt/playground/backend/executable_files/
7575

76+
RUN pip install apache-beam[gcp,interactive]==$BEAM_VERSION
77+
7678
# Chown all required files to the `appuser`.
7779
RUN chown -R appuser:appgroup /opt/playground/backend/executable_files/ && chmod +x /entrypoint.sh
7880

playground/infrastructure/cloudbuild/playground_cd_examples.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ LogOutput "Input variables:
8282
BEAM_USE_WEBGRPC=$BEAM_USE_WEBGRPC
8383
DATASTORE_NAMESPACE=$DATASTORE_NAMESPACE
8484
FORCE_CD=$FORCE_CD"
85-
85+
8686

8787
# Script starts in a clean environment in Cloud Build. Set minimal required environment variables
8888
if [ -z "$PATH" ]; then
@@ -110,6 +110,7 @@ apt install -y python3.10-venv > /dev/null 2>&1
110110
LogOutput "Installing Python packages from beam/playground/infrastructure/requirements.txt"
111111
cd $BEAM_ROOT_DIR
112112
pip install -r playground/infrastructure/requirements.txt
113+
pip install setuptools
113114

114115
LogOutput "Looking for files changed by the merge commit $MERGE_COMMIT"
115116
git fetch origin $MERGE_COMMIT
@@ -130,7 +131,7 @@ do
130131
LogOutput "FORCE_CD is true. Example deployment for SDK_${sdk^^} is forced"
131132
example_has_changed="true"
132133
else
133-
LogOutput "------------------Starting checker.py for SDK_${sdk^^}------------------"
134+
LogOutput "------------------Starting checker.py for SDK_${sdk^^}------------------"
134135
cd $BEAM_ROOT_DIR/playground/infrastructure
135136
python3 checker.py \
136137
--verbose \
@@ -159,7 +160,7 @@ do
159160
eval "check_${sdk}_passed"="true"
160161
continue
161162
fi
162-
163+
163164
cd $BEAM_ROOT_DIR/playground/infrastructure
164165
LogOutput "Running ci_cd.py for SDK $sdk"
165166

@@ -187,4 +188,4 @@ do
187188
exit 1
188189
fi
189190
done
190-
exit 0
191+
exit 0

0 commit comments

Comments
 (0)