feat: PLANNING体系首版(00路线图/02任务总表/03执行协议/I-03/I-04/registry42口径)+M1止血交付
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
FROM ubuntu:22.04
|
||||
|
||||
# Prevent interactive prompts
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# Install dependencies
|
||||
RUN apt-get update && apt-get install -y \
|
||||
curl \
|
||||
wget \
|
||||
unzip \
|
||||
git \
|
||||
openjdk-17-jdk \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Set up Android SDK
|
||||
ENV ANDROID_HOME=/opt/android-sdk
|
||||
ENV ANDROID_SDK_ROOT=/opt/android-sdk
|
||||
ENV PATH=$PATH:$ANDROID_HOME/cmdline-tools/latest/bin:$ANDROID_HOME/platform-tools
|
||||
|
||||
# Download and install Android SDK command line tools
|
||||
RUN mkdir -p $ANDROID_HOME/cmdline-tools && \
|
||||
cd $ANDROID_HOME/cmdline-tools && \
|
||||
wget -q https://dl.google.com/android/repository/commandlinetools-linux-11076708_latest.zip -O cmdline-tools.zip && \
|
||||
unzip cmdline-tools.zip && \
|
||||
mv cmdline-tools latest && \
|
||||
rm cmdline-tools.zip
|
||||
|
||||
# Accept licenses and install required SDK components
|
||||
RUN yes | sdkmanager --licenses && \
|
||||
sdkmanager "platform-tools" "platforms;android-34" "build-tools;34.0.0"
|
||||
|
||||
# Copy the Android project
|
||||
WORKDIR /app
|
||||
COPY android-chunyu/ .
|
||||
|
||||
# Make gradlew executable
|
||||
RUN chmod +x gradlew
|
||||
|
||||
# Build the debug APK
|
||||
RUN ./gradlew assembleDebug --no-daemon
|
||||
|
||||
# Copy APK to expected location
|
||||
RUN mkdir -p /output && \
|
||||
cp app/build/outputs/apk/debug/app-debug.apk /output/ && \
|
||||
echo "APK built successfully!" && \
|
||||
ls -la /output/
|
||||
|
||||
# Output APK location
|
||||
VOLUME ["/output"]
|
||||
Reference in New Issue
Block a user