Dockerfile 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. FROM debian:buster-20200514-slim
  2. LABEL \
  3. maintainer="Michel Stempin <michel.stempin@funkey-project.com>" \
  4. vendor="FunKey Project" \
  5. description="Container with everything needed to build FunKey-OS"
  6. # Setup environment
  7. ENV DEBIAN_FRONTEND noninteractive
  8. # This repository can be a bit slow at times. Don't panic...
  9. COPY apt-sources.list /etc/apt/sources.list
  10. RUN \
  11. # Install dependencies
  12. # See https://buildroot.org/downloads/manual/manual.html#requirement
  13. apt-get update && \
  14. apt-get install -y -q --no-install-recommends \
  15. # MANDATORY build tools
  16. #which \
  17. #sed \
  18. make \
  19. binutils \
  20. build-essential \
  21. gcc \
  22. g++ \
  23. #bash \
  24. patch \
  25. #gzip \
  26. bzip2 \
  27. perl \
  28. #tar \
  29. cpio \
  30. unzip \
  31. rsync \
  32. file \
  33. bc \
  34. # MANDATORY source fetching tools
  35. wget \
  36. # OPTIONAL recommended dependencies
  37. python \
  38. # OPTIONAL configuration interface dependencies
  39. libncurses5-dev \
  40. #libqt5-dev \
  41. #libglib2.0-dev libgtk2.0-dev libglade2-dev \
  42. # OPTIONAL source fetching tools
  43. #bazaar \
  44. # bzr \
  45. cvs \
  46. git \
  47. mercurial \
  48. rsync \
  49. liblscp-dev \
  50. subversion \
  51. # OPTIONAL java related packages
  52. #javacc \
  53. #jarwrapper \
  54. # OPTIONAL documentation generation tools
  55. #asciidoc \
  56. #w3m \
  57. #python3 \
  58. #dblatex \
  59. # OPTIONAL graph generation tools
  60. #graphviz \
  61. #python-matplotlib \
  62. #
  63. # ADDITIONAL dependency to get root certificates
  64. ca-certificates \
  65. # ADDITIONAL dependency to get client ssh
  66. openssh-client \
  67. # ADDITIONAL dependency to get unbuffer
  68. expect \
  69. # ADDITIONAL dependency to get locale-gen
  70. locales \
  71. # ADDITIONAL nice to have dependencies
  72. sudo \
  73. procps \
  74. && \
  75. apt-get -y autoremove && \
  76. apt-get -y clean && \
  77. rm -rf /var/lib/apt/lists/* && \
  78. #
  79. # Set locale
  80. sed -i 's/# \(en_US.UTF-8\)/\1/' /etc/locale.gen && \
  81. locale-gen --purge --lang en_US.UTF-8 && \
  82. #
  83. # Add user
  84. useradd -ms /bin/bash funkey && \
  85. usermod -a -G sudo funkey && \
  86. echo "funkey:funkey" | chpasswd && \
  87. #
  88. # Create skeleton directories
  89. # mkdir -p /home/funkey/.buildroot-ccache \
  90. # /home/funkey/FunKey-OS/buildroot \
  91. # /home/funkey/FunKey-OS/FunKey/dl \
  92. # /home/funkey/FunKey-OS/FunKey/output/build \
  93. # /home/funkey/FunKey-OS/FunKey/output/host \
  94. # /home/funkey/FunKey-OS/FunKey/output/target && \
  95. #
  96. # Set file ownership
  97. chown -R funkey:funkey /home/funkey
  98. # Set user
  99. USER funkey
  100. # Set environment
  101. ENV \
  102. HOME=/home/funkey \
  103. LC_ALL=en_US.UTF-8 \
  104. BR2_EXTERNAL=../FunKey \
  105. O=../FunKey/output
  106. # Set working directory
  107. WORKDIR /home/funkey/
  108. #WORKDIR /home/funkey/FunKey-OS
  109. # VOLUME ["/home/funkey/.buildroot-ccache", \
  110. # "/home/funkey/FunKey-OS/buildroot", \
  111. # "/home/funkey/FunKey-OS/FunKey/dl", \
  112. # "/home/funkey/FunKey-OS/FunKey/output/build", \
  113. # "/home/funkey/FunKey-OS/FunKey/output/host", \
  114. # "/home/funkey/FunKey-OS/FunKey/output/target"]
  115. #CMD ["/bin/bash"]