-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathflutter
32 lines (25 loc) · 1.18 KB
/
flutter
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
FROM mobiledevops/android-sdk-image:33.0.2
USER root
RUN apt-get update --yes && apt-get install lcov --yes --quiet && apt-get install -y xdg-user-dirs
RUN chown -R mobiledevops:mobiledevops $HOME
USER mobiledevops
ENV FLUTTER_VERSION="3.22.0"
ENV FLUTTER_HOME "/home/mobiledevops/.flutter-sdk"
ENV PATH $PATH:$FLUTTER_HOME/bin
# Download and extract Flutter SDK
RUN mkdir $FLUTTER_HOME \
&& cd $FLUTTER_HOME \
&& curl --fail --remote-time --silent --location -O https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_${FLUTTER_VERSION}-stable.tar.xz \
&& tar xf flutter_linux_${FLUTTER_VERSION}-stable.tar.xz --strip-components=1 \
&& rm flutter_linux_${FLUTTER_VERSION}-stable.tar.xz
RUN flutter precache
# SETUP VeryGoodCLI
# so we can use an optimize version of 'flutter test', very_good test for a faster result on test coverage
RUN dart pub global activate very_good_cli
# SETUP FIREBASE & FLUTTERFIRE CLIs
USER root
RUN git config --global --add safe.directory $FLUTTER_HOME
RUN curl -sL https://firebase.tools | sed 's/sudo //g' | bash
RUN dart pub global activate flutterfire_cli
RUN chown -R mobiledevops:mobiledevops $HOME
USER mobiledevops