Dockerfile 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. FROM archlinux/archlinux:base-devel
  2. RUN pacman -Syy
  3. RUN pacman -Syu --needed --noconfirm git xdg-user-dirs
  4. # makepkg user and workdir
  5. ARG user=makepkg
  6. ENV PATH="/home/makepkg/.local/flutter/bin:/home/makepkg/.local/flutter/bin/cache/dart-sdk/bin:${PATH}"
  7. RUN useradd --system --create-home $user \
  8. && echo "$user ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers.d/$user
  9. USER $user
  10. WORKDIR /home/$user
  11. # Install yay
  12. RUN git clone https://aur.archlinux.org/yay.git \
  13. && cd yay \
  14. && makepkg -sri --needed --noconfirm \
  15. && cd \
  16. && rm -rf .cache yay
  17. RUN yay -S --noconfirm curl base-devel sqlite openssl clang cmake ninja pkg-config gtk3 unzip
  18. RUN xdg-user-dirs-update
  19. RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
  20. RUN source $HOME/.cargo/env && rustup toolchain install stable && rustup default stable
  21. RUN git clone https://github.com/flutter/flutter.git $HOME/.local/flutter
  22. RUN flutter channel stable
  23. RUN flutter config --enable-linux-desktop
  24. RUN flutter doctor
  25. RUN git clone https://github.com/AppFlowy-IO/appflowy.git && \
  26. cd appflowy/frontend && \
  27. source $HOME/.cargo/env && \
  28. cargo install --force cargo-make && \
  29. cargo install --force duckscript_cli && \
  30. cargo make flowy_dev && \
  31. cargo make -p production-linux-x86 appflowy-linux
  32. CMD ["appflowy/frontend/app_flowy/product/0.0.3/linux/Release/AppFlowy/app_flowy"]