Remove Tian Lee from committers and update TSC section
[aai/sparky-be.git] / sparkybe-onap-application / src / main / docker / Dockerfile
1 FROM @aai.docker.namespace@/aai-common-@aai.base.image@:@aai.base.image.version@
2
3 ARG MICRO_HOME=/opt/app/sparky
4 ARG BIN_HOME=$MICRO_HOME/bin
5
6 # Build up the deployment folder structure
7 RUN mkdir -p $MICRO_HOME
8
9 # Changes related to:AAI-2180
10 # Additional optional steps for Ubuntu
11 RUN if  ((uname -v | grep -i "ubuntu") || ( cat /etc/*release|grep -i "ubuntu")      ) ; then \
12    #####################################
13    #if JAVA doesnt exist then install it: 
14    ######################################
15    if type  java  2>/dev/null; then \   
16      echo "skipping java installation"; \       
17    else \
18      apt-get update && apt-get install -y software-properties-common; \
19      ## sudo -E is required to preserve the environment. If you remove that line, it will most like freeze at this step
20      sudo -E add-apt-repository ppa:openjdk-r/ppa && apt-get update && apt-get install -y openjdk-8-jdk ; \
21      ## Setup JAVA_HOME, this is useful for docker commandline
22      JAVA_HOME=usr/lib/jvm/java-8-openjdk-amd64; \
23      export JAVA_HOME ; \
24    fi; \
25    ##########################################
26    #Install gosu if not present
27    ##########################################  
28    if type  gosu   2>/dev/null; then \     
29      echo "skipping gosu installation"; \
30    else \
31      set -x ; \
32      add-apt-repository -y ppa:tianon/gosu; \ 
33      sudo apt-get update; \
34      sudo apt-get install gosu; \
35    fi;\
36 fi
37 WORKDIR $MICRO_HOME
38 COPY /maven/sparkybe-onap-application/ .
39 RUN chmod 755 $BIN_HOME/* \
40     && ln -snf /logs $MICRO_HOME/logs
41
42 EXPOSE 8000 8000
43 EXPOSE 9517 9517
44     
45 CMD ["/opt/app/sparky/bin/start.sh"]