ffead-cpp-apache-mysql.dockerfile 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. FROM buildpack-deps:xenial
  2. ENV IROOT=/installs
  3. ENV FFEAD_CPP_PATH=${IROOT}/ffead-cpp-2.0
  4. ENV PATH=${FFEAD_CPP_PATH}:${PATH}
  5. RUN mkdir /installs
  6. RUN apt update -yqq && apt install -yqq unzip uuid-dev odbc-postgresql unixodbc unixodbc-dev
  7. WORKDIR $IROOT
  8. # libmyodbc has been removed from apt
  9. RUN wget -q http://www.mirrorservice.org/sites/ftp.mysql.com/Downloads/Connector-ODBC/5.3/mysql-connector-odbc-5.3.10-linux-ubuntu16.04-x86-64bit.tar.gz
  10. RUN tar xf mysql-connector-odbc-5.3.10-linux-ubuntu16.04-x86-64bit.tar.gz
  11. RUN mkdir -p /usr/lib/x86_64-linux-gnu/odbc
  12. RUN mv mysql-connector-odbc-5.3.10-linux-ubuntu16.04-x86-64bit/lib/libmyodbc5* /usr/lib/x86_64-linux-gnu/odbc/
  13. RUN mysql-connector-odbc-5.3.10-linux-ubuntu16.04-x86-64bit/bin/myodbc-installer -d -a -n "MySQL" -t "DRIVER=/usr/lib/x86_64-linux-gnu/odbc/libmyodbc5w.so;"
  14. # mongocdriver also used in all tests
  15. RUN wget -q https://github.com/mongodb/mongo-c-driver/releases/download/1.4.0/mongo-c-driver-1.4.0.tar.gz
  16. RUN tar xf mongo-c-driver-1.4.0.tar.gz
  17. RUN cd mongo-c-driver-1.4.0/ && \
  18. ./configure --prefix=${IROOT} --libdir=${IROOT} --disable-automatic-init-and-cleanup && \
  19. make && make install
  20. WORKDIR /
  21. COPY te-benchmark/ te-benchmark/
  22. COPY ffead-cpp-framework.sh ./
  23. COPY server.sh ./
  24. RUN chmod 755 *.sh
  25. RUN ./ffead-cpp-framework.sh
  26. COPY ffead-cpp-httpd.sh ./
  27. RUN chmod 755 *.sh
  28. RUN ./ffead-cpp-httpd.sh
  29. ENV PATH=${IROOT}/httpd/bin:${PATH}
  30. WORKDIR ${IROOT}/ffead-cpp-src/
  31. RUN cp -f web/te-benchmark/sql-src/TeBkWorldsql.h web/te-benchmark/include/TeBkWorld.h
  32. RUN cp -f web/te-benchmark/sql-src/TeBkWorldsql.cpp web/te-benchmark/src/TeBkWorld.cpp
  33. RUN cp -f web/te-benchmark/config/sdormmysql.xml web/te-benchmark/config/sdorm.xml
  34. RUN rm -rf ffead-cpp-2.0-bin
  35. RUN make build-apps
  36. RUN rm -rf ${IROOT}/ffead-cpp-2.0
  37. RUN cp -rf ffead-cpp-2.0-bin ${IROOT}/ffead-cpp-2.0
  38. WORKDIR ${IROOT}/ffead-cpp-2.0
  39. RUN rm -rf web/default web/oauthApp web/flexApp web/markers
  40. RUN chmod 755 *.sh resources/*.sh rtdcf/autotools/*.sh
  41. RUN chmod 755 $FFEAD_CPP_PATH/*.sh
  42. RUN rm -f $FFEAD_CPP_PATH/*.cntrl
  43. RUN rm -f $FFEAD_CPP_PATH/tmp/*.sess
  44. CMD apachectl -D FOREGROUND