Dockerfile 720 Bytes
Newer Older
1
FROM 10.19.0-stretch
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25

RUN useradd -ms /bin/bash mc

WORKDIR /home/mc

RUN apt-get update
RUN apt-get -yq install nginx

COPY . mc_frontend

COPY nginx.conf /etc/nginx/nginx.conf
RUN install -Dv /dev/null /run/nginx/nginx.pid

#RUN chown -R mc:mc ./
#USER mc

WORKDIR /home/mc/mc_frontend
RUN npm i -g cordova && cordova telemetry off && npm i -g ionic
# to get the version of the local CLI package, run: npm list @angular/cli | sed 's/[^0-9.]*//g' | sed -n 2p
RUN npm i -g @angular/cli

RUN npm install
# workaround to fix the missing binding issue for node-sass
RUN npm rebuild node-sass
26
# TODO: for some reason, this does not persist?!?!??!
27
# RUN ionic cordova build browser --prod --release --max-old-space-size=4096