-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile-cordova
30 lines (26 loc) · 1.09 KB
/
Dockerfile-cordova
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
# Node 18, API:27-34
FROM cimg/android:2023.08-browsers
WORKDIR /home/circleci/project
USER circleci
RUN npm install cordova@12
ENV PATH=$PATH:/home/circleci/project/node_modules/cordova/bin/
ENV ENVIRONMENT=staging
RUN cordova telemetry off
COPY --chown=circleci . /home/circleci/project/
# docker build -f Dockerfile-cordova -t goodcity:latest .
# docker run -it goodcity:latest /bin/bash
# cordova build android --debug --device
#
# With Gradle stacktrace (useful for build errors)
# cd platforms/android
# ./gradlew --info cdvBuildDebug -b build.gradle
# Gradle logs are in ~/.gradle/daemon
# ADVANCED USAGE KEEPS IMAGE RUNNING TO MAINTAIN GRADLE CACHE
# ENVIRONMENT=staging EMBER_CLI_CORDOVA=1 yarn run ember build
# cd cordova
# ln -s ../dist www
# cordova platform add android@12
# cd ..
# docker run -i --rm -v `pwd`/dist/:/home/circleci/project/dist/ -v `pwd`/cordova:/home/circleci/project/cordova/ -w /home/circleci/project/cordova/ -u root -t goodcity:latest /bin/bash
# cordova build android --debug --device
# App located in `pwd`/cordova/platforms/android/app/build/outputs/apk/debug/app-debug.apk