|
|
FROM archlinux:latest |
|
|
|
|
|
RUN echo -e "[multilib]\nInclude = /etc/pacman.d/mirrorlist" >> /etc/pacman.conf \ |
|
|
&& echo -e "[archlinuxcn]\nServer = https://mirrors.aliyun.com/archlinuxcn/\$arch" >> /etc/pacman.conf \ |
|
|
&& echo -e "[chaotic-aur]\nServer = https://geo-mirror.chaotic.cx/\$repo/\$arch" >> /etc/pacman.conf \ |
|
|
&& echo -e "[atri]\nServer = https://repo.apeiria.net/\$arch" >> /etc/pacman.conf |
|
|
|
|
|
RUN pacman-key --init \ |
|
|
&& pacman-key --lsign-key "farseerfc@archlinux.org" \ |
|
|
&& pacman-key --recv-key 3056513887B78AEB --keyserver keyserver.ubuntu.com \ |
|
|
&& pacman-key --lsign-key 3056513887B78AEB \ |
|
|
&& pacman-key --recv-keys 293B93D8A471059F85D716A65BA92099D9BE2DAA \ |
|
|
&& pacman-key --lsign-key 293B93D8A471059F85D716A65BA92099D9BE2DAA \ |
|
|
&& pacman -Sy --noconfirm archlinuxcn-keyring |
|
|
|
|
|
RUN pacman -Syu --noconfirm yay |
|
|
|
|
|
RUN yay -S --noconfirm \ |
|
|
aria2 \ |
|
|
base-devel \ |
|
|
clang \ |
|
|
cmake \ |
|
|
code-server \ |
|
|
code-server-marketplace \ |
|
|
curl \ |
|
|
deno \ |
|
|
direnv \ |
|
|
fisher \ |
|
|
fish \ |
|
|
gcc \ |
|
|
git \ |
|
|
git-lfs \ |
|
|
go \ |
|
|
intel-oneapi-basekit \ |
|
|
jq \ |
|
|
nix \ |
|
|
nodejs \ |
|
|
openblas64 \ |
|
|
openssh \ |
|
|
p7zip \ |
|
|
pkgconf \ |
|
|
pkgfile \ |
|
|
pypy \ |
|
|
python \ |
|
|
python-pip \ |
|
|
ruff \ |
|
|
rust \ |
|
|
rye \ |
|
|
screen \ |
|
|
tinygo \ |
|
|
unzip \ |
|
|
uv \ |
|
|
wget \ |
|
|
xmake \ |
|
|
zig \ |
|
|
zip \ |
|
|
&& yay -Scc --noconfirm \ |
|
|
&& rm -rf /var/cache/pacman/* |
|
|
|
|
|
RUN aria2c -c -x16 https://hf-mirror.com/hfd/hfd.sh \ |
|
|
&& chmod a+x hfd.sh \ |
|
|
&& mv hfd.sh /usr/bin/hfd |
|
|
|
|
|
RUN pkgfile --update |
|
|
|
|
|
RUN git lfs install |
|
|
|
|
|
RUN corepack prepare pnpm@latest \ |
|
|
&& corepack enable pnpm |
|
|
|
|
|
COPY fish-oneapi /usr/bin/fish-oneapi |
|
|
|
|
|
RUN chmod +x /usr/bin/fish-oneapi |
|
|
|
|
|
RUN useradd -m -s /usr/bin/fish-oneapi mzwing |
|
|
|
|
|
USER mzwing |
|
|
|
|
|
WORKDIR /home/mzwing |
|
|
|
|
|
RUN mkdir -p /home/mzwing/.ssh |
|
|
|
|
|
RUN plugins=( \ |
|
|
"danhper/fish-ssh-agent" \ |
|
|
"jethrokuan/z" \ |
|
|
"franciscolourenco/done" \ |
|
|
"jorgebucaran/autopair.fish" \ |
|
|
) \ |
|
|
&& for plugin in "${plugins[@]}"; do \ |
|
|
fish -c "fisher install $plugin"; \ |
|
|
done |
|
|
|
|
|
RUN rye toolchain register /usr/bin/python \ |
|
|
&& rye toolchain register /usr/bin/pypy |
|
|
|
|
|
RUN fish -c 'SHELL=/usr/bin/fish pnpm setup' |
|
|
|
|
|
RUN mkdir -p /home/mzwing/.config/code-server/ |
|
|
|
|
|
|
|
|
RUN echo -e "bind-addr: 0.0.0.0:8080\nauth: password\ncert: false" > /home/mzwing/.config/code-server/config.yaml |
|
|
|
|
|
RUN extensions=( \ |
|
|
"aaron-bond.better-comments" \ |
|
|
"ahmadalli.vscode-nginx-conf" \ |
|
|
"alefragnani.bookmarks" \ |
|
|
"aminer.codegeex" \ |
|
|
"antfu.browse-lite" \ |
|
|
"antfu.vite" \ |
|
|
"arrterian.nix-env-selector" \ |
|
|
"bbenoist.nix" \ |
|
|
"bierner.lit-html" \ |
|
|
"christian-kohler.npm-intellisense" \ |
|
|
"christian-kohler.path-intellisense" \ |
|
|
"claui.packaging" \ |
|
|
"codeium.codeium" \ |
|
|
"codezombiech.gitignore" \ |
|
|
"dart-code.dart-code" \ |
|
|
"dart-code.flutter" \ |
|
|
"davidanson.vscode-markdownlint" \ |
|
|
"dbaeumer.vscode-eslint" \ |
|
|
"denoland.vscode-deno" \ |
|
|
"donjayamanne.githistory" \ |
|
|
"eamodio.gitlens" \ |
|
|
"editorconfig.editorconfig" \ |
|
|
"esbenp.prettier-vscode" \ |
|
|
"fill-labs.dependi" \ |
|
|
"formulahendry.auto-close-tag" \ |
|
|
"formulahendry.auto-rename-tag" \ |
|
|
"gera2ld.markmap-vscode" \ |
|
|
"get-snippets.get-snippets" \ |
|
|
"github.codespaces" \ |
|
|
"github.copilot" \ |
|
|
"github.copilot-chat" \ |
|
|
"github.remotehub" \ |
|
|
"github.vscode-github-actions" \ |
|
|
"golang.go" \ |
|
|
"graphql.vscode-graphql-syntax" \ |
|
|
"gruntfuggly.todo-tree" \ |
|
|
"jeff-hykin.better-dockerfile-syntax" \ |
|
|
"jnoortheen.nix-ide" \ |
|
|
"justjavac.vscode-deno-extensionpack" \ |
|
|
"laurencebahiirwa.deno-std-lib-snippets" \ |
|
|
"lit.lit-snippets" \ |
|
|
"matthewpi.caddyfile-support" \ |
|
|
"mechatroner.rainbow-csv" \ |
|
|
"mhutchie.git-graph" \ |
|
|
"mirone.milkdown" \ |
|
|
"misterj.vue-volar-extention-pack" \ |
|
|
"mkhl.direnv" \ |
|
|
"mrmlnc.vscode-json5" \ |
|
|
"ms-dotnettools.csdevkit" \ |
|
|
"ms-dotnettools.csharp" \ |
|
|
"ms-dotnettools.vscode-dotnet-runtime" \ |
|
|
"ms-dotnettools.vscodeintellicode-csharp" \ |
|
|
"ms-python.black-formatter" \ |
|
|
"ms-python.debugpy" \ |
|
|
"ms-python.python" \ |
|
|
"ms-python.vscode-pylance" \ |
|
|
"ms-toolsai.jupyter" \ |
|
|
"ms-toolsai.jupyter-keymap" \ |
|
|
"ms-toolsai.jupyter-renderers" \ |
|
|
"ms-toolsai.vscode-jupyter-cell-tags" \ |
|
|
"ms-toolsai.vscode-jupyter-slideshow" \ |
|
|
"ms-vscode.azure-repos" \ |
|
|
"ms-vscode.cmake-tools" \ |
|
|
"ms-vscode.cpptools" \ |
|
|
"ms-vscode.cpptools-extension-pack" \ |
|
|
"ms-vscode.cpptools-themes" \ |
|
|
"ms-vscode.remote-repositories" \ |
|
|
"msyrus.go-doc" \ |
|
|
"njpwerner.autodocstring" \ |
|
|
"oderwat.indent-rainbow" \ |
|
|
"pinage404.nix-extension-pack" \ |
|
|
"redhat.vscode-xml" \ |
|
|
"redhat.vscode-yaml" \ |
|
|
"rickyang.ocopilot" \ |
|
|
"rust-lang.rust-analyzer" \ |
|
|
"rxliuli.tsx" \ |
|
|
"saoudrizwan.claude-dev" \ |
|
|
"sibiraj-s.vscode-scss-formatter" \ |
|
|
"swellaby.rust-pack" \ |
|
|
"syler.sass-indented" \ |
|
|
"tabnine.tabnine-vscode" \ |
|
|
"tamasfe.even-better-toml" \ |
|
|
"timonwong.shellcheck" \ |
|
|
"twxs.cmake" \ |
|
|
"visualstudioexptteam.intellicode-api-usage-examples" \ |
|
|
"visualstudioexptteam.vscodeintellicode" \ |
|
|
"visualstudioexptteam.vscodeintellicode-completions" \ |
|
|
"vitaliymaz.vscode-svg-previewer" \ |
|
|
"vitest.explorer" \ |
|
|
"vue.volar" \ |
|
|
"wayou.vscode-todo-highlight" \ |
|
|
) \ |
|
|
&& for extension in "${extensions[@]}"; do \ |
|
|
code-server --config /home/mzwing/.config/code-server/config.yaml --install-extension "$extension"; \ |
|
|
done |
|
|
|
|
|
RUN code-server --config /home/mzwing/.config/code-server/config.yaml --uninstall-extension "serayuzgur.crates" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
EXPOSE 8080 |
|
|
|
|
|
CMD ["code-server", "--config", "/home/mzwing/.config/code-server/config.yaml"] |
|
|
|