Dockerfile 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  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. RUN \
  9. # Install dependencies
  10. # See https://buildroot.org/downloads/manual/manual.html#requirement
  11. apt-get update && \
  12. apt-get install -y -q --no-install-recommends \
  13. # MANDATORY build tools
  14. #which \
  15. #sed \
  16. make \
  17. binutils \
  18. build-essential \
  19. gcc \
  20. g++ \
  21. #bash \
  22. patch \
  23. #gzip \
  24. bzip2 \
  25. perl \
  26. #tar \
  27. cpio \
  28. unzip \
  29. rsync \
  30. file \
  31. bc \
  32. # MANDATORY source fetching tools
  33. wget \
  34. # OPTIONAL recommended dependencies
  35. python \
  36. python-dev \
  37. xxd \
  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. python3-dev \
  59. python3-distutils \
  60. python3-setuptools \
  61. #dblatex \
  62. # OPTIONAL graph generation tools
  63. #graphviz \
  64. #python-matplotlib \
  65. #
  66. # ADDITIONAL dependency to get root certificates
  67. ca-certificates \
  68. # ADDITIONAL dependency to get client ssh
  69. openssh-client \
  70. # ADDITIONAL dependency to get unbuffer
  71. expect \
  72. # ADDITIONAL dependency to get locale-gen
  73. locales \
  74. # ADDITIONAL nice to have dependencies
  75. sudo \
  76. procps \
  77. && \
  78. apt-get -y autoremove && \
  79. apt-get -y clean && \
  80. rm -rf /var/lib/apt/lists/* && \
  81. #
  82. # Set locale
  83. sed -i 's/# \(en_US.UTF-8\)/\1/' /etc/locale.gen && \
  84. locale-gen --purge --lang en_US.UTF-8 && \
  85. #
  86. # Add user
  87. useradd -ms /bin/bash funkey && \
  88. usermod -a -G sudo funkey && \
  89. echo "funkey:funkey" | chpasswd && \
  90. #
  91. # Clone the FunKey-OS repository
  92. git clone https://github.com/FunKey-Project/FunKey-OS.git /home/funkey/FunKey-OS && \
  93. #
  94. # Set file ownership
  95. chown -R funkey:funkey /home/funkey
  96. # Set user
  97. USER funkey
  98. # Set working directory
  99. WORKDIR /home/funkey/FunKey-OS
  100. # Set environment
  101. ENV \
  102. HOME=/home/funkey \
  103. LC_ALL=en_US.UTF-8
  104. # VOLUME ["/home/funkey/.buildroot-ccache", \
  105. # "/home/funkey/FunKey-OS/buildroot", \
  106. # "/home/funkey/FunKey-OS/dowload", \
  107. # "/home/funkey/FunKey-OS/images", \
  108. # "/home/funkey/FunKey-OS/Recovery/output/build", \
  109. # "/home/funkey/FunKey-OS/Recovery/output/host", \
  110. # "/home/funkey/FunKey-OS/Recovery/output/target", \
  111. # "/home/funkey/FunKey-OS/FunKey/output/host", \
  112. # "/home/funkey/FunKey-OS/FunKey/output/build", \
  113. # "/home/funkey/FunKey-OS/FunKey/output/target"]
  114. CMD ["/usr/bin/make", "sdk", "all", "-C", "/home/funkey/FunKey-OS"]