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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM archlinux:latest
|
| 2 |
+
|
| 3 |
+
RUN echo -e "[multilib]\nInclude = /etc/pacman.d/mirrorlist" >> /etc/pacman.conf \
|
| 4 |
+
&& echo -e "[archlinuxcn]\nServer = https://mirrors.aliyun.com/archlinuxcn/\$arch" >> /etc/pacman.conf \
|
| 5 |
+
&& echo -e "[chaotic-aur]\nServer = https://geo-mirror.chaotic.cx/\$repo/\$arch" >> /etc/pacman.conf \
|
| 6 |
+
&& echo -e "[atri]\nServer = https://repo.apeiria.net/\$arch" >> /etc/pacman.conf
|
| 7 |
+
|
| 8 |
+
RUN pacman-key --init \
|
| 9 |
+
&& pacman-key --lsign-key "farseerfc@archlinux.org" \
|
| 10 |
+
&& pacman-key --recv-key 3056513887B78AEB --keyserver keyserver.ubuntu.com \
|
| 11 |
+
&& pacman-key --lsign-key 3056513887B78AEB \
|
| 12 |
+
&& pacman-key --recv-keys 293B93D8A471059F85D716A65BA92099D9BE2DAA \
|
| 13 |
+
&& pacman-key --lsign-key 293B93D8A471059F85D716A65BA92099D9BE2DAA \
|
| 14 |
+
&& pacman -Sy --noconfirm archlinuxcn-keyring
|
| 15 |
+
|
| 16 |
+
RUN pacman -Syu --noconfirm yay
|
| 17 |
+
|
| 18 |
+
RUN yay -S --noconfirm \
|
| 19 |
+
aria2 \
|
| 20 |
+
base-devel \
|
| 21 |
+
clang \
|
| 22 |
+
cmake \
|
| 23 |
+
code-server \
|
| 24 |
+
code-server-marketplace \
|
| 25 |
+
curl \
|
| 26 |
+
deno \
|
| 27 |
+
direnv \
|
| 28 |
+
fisher \
|
| 29 |
+
fish \
|
| 30 |
+
gcc \
|
| 31 |
+
git \
|
| 32 |
+
git-lfs \
|
| 33 |
+
go \
|
| 34 |
+
intel-oneapi-basekit \
|
| 35 |
+
jq \
|
| 36 |
+
nix \
|
| 37 |
+
nodejs \
|
| 38 |
+
openblas64 \
|
| 39 |
+
openssh \
|
| 40 |
+
p7zip \
|
| 41 |
+
pkgconf \
|
| 42 |
+
pkgfile \
|
| 43 |
+
pypy \
|
| 44 |
+
python \
|
| 45 |
+
python-pip \
|
| 46 |
+
ruff \
|
| 47 |
+
rust \
|
| 48 |
+
rye \
|
| 49 |
+
screen \
|
| 50 |
+
tinygo \
|
| 51 |
+
unzip \
|
| 52 |
+
uv \
|
| 53 |
+
wget \
|
| 54 |
+
xmake \
|
| 55 |
+
zig \
|
| 56 |
+
zip \
|
| 57 |
+
&& yay -Scc --noconfirm \
|
| 58 |
+
&& rm -rf /var/cache/pacman/*
|
| 59 |
+
|
| 60 |
+
RUN aria2c -c -x16 https://hf-mirror.com/hfd/hfd.sh \
|
| 61 |
+
&& chmod a+x hfd.sh \
|
| 62 |
+
&& mv hfd.sh /usr/bin/hfd
|
| 63 |
+
|
| 64 |
+
RUN pkgfile --update
|
| 65 |
+
|
| 66 |
+
RUN git lfs install
|
| 67 |
+
|
| 68 |
+
RUN corepack prepare pnpm@latest \
|
| 69 |
+
&& corepack enable pnpm
|
| 70 |
+
|
| 71 |
+
COPY fish-oneapi /usr/bin/fish-oneapi
|
| 72 |
+
|
| 73 |
+
RUN chmod +x /usr/bin/fish-oneapi
|
| 74 |
+
|
| 75 |
+
RUN useradd -m -s /usr/bin/fish-oneapi mzwing
|
| 76 |
+
|
| 77 |
+
USER mzwing
|
| 78 |
+
|
| 79 |
+
WORKDIR /home/mzwing
|
| 80 |
+
|
| 81 |
+
RUN mkdir -p /home/mzwing/.ssh
|
| 82 |
+
|
| 83 |
+
RUN plugins=( \
|
| 84 |
+
"danhper/fish-ssh-agent" \
|
| 85 |
+
"jethrokuan/z" \
|
| 86 |
+
"franciscolourenco/done" \
|
| 87 |
+
"jorgebucaran/autopair.fish" \
|
| 88 |
+
) \
|
| 89 |
+
&& for plugin in "${plugins[@]}"; do \
|
| 90 |
+
fish -c "fisher install $plugin"; \
|
| 91 |
+
done
|
| 92 |
+
|
| 93 |
+
RUN rye toolchain register /usr/bin/python \
|
| 94 |
+
&& rye toolchain register /usr/bin/pypy
|
| 95 |
+
|
| 96 |
+
RUN fish -c 'SHELL=/usr/bin/fish pnpm setup'
|
| 97 |
+
|
| 98 |
+
RUN mkdir -p /home/mzwing/.config/code-server/ \
|
| 99 |
+
&& touch /home/mzwing/.config/code-server/config.yaml \
|
| 100 |
+
&& echo -e "bind-addr: 0.0.0.0:8080\nauth: password\ncert: false" > /home/mzwing/.config/code-server/config.yaml
|
| 101 |
+
|
| 102 |
+
RUN extensions=( \
|
| 103 |
+
"aaron-bond.better-comments" \
|
| 104 |
+
"ahmadalli.vscode-nginx-conf" \
|
| 105 |
+
"alefragnani.bookmarks" \
|
| 106 |
+
"aminer.codegeex" \
|
| 107 |
+
"antfu.browse-lite" \
|
| 108 |
+
"antfu.vite" \
|
| 109 |
+
"arrterian.nix-env-selector" \
|
| 110 |
+
"bbenoist.nix" \
|
| 111 |
+
"bierner.lit-html" \
|
| 112 |
+
"christian-kohler.npm-intellisense" \
|
| 113 |
+
"christian-kohler.path-intellisense" \
|
| 114 |
+
"claui.packaging" \
|
| 115 |
+
"codeium.codeium" \
|
| 116 |
+
"codezombiech.gitignore" \
|
| 117 |
+
"dart-code.dart-code" \
|
| 118 |
+
"dart-code.flutter" \
|
| 119 |
+
"davidanson.vscode-markdownlint" \
|
| 120 |
+
"dbaeumer.vscode-eslint" \
|
| 121 |
+
"denoland.vscode-deno" \
|
| 122 |
+
"donjayamanne.githistory" \
|
| 123 |
+
"eamodio.gitlens" \
|
| 124 |
+
"editorconfig.editorconfig" \
|
| 125 |
+
"esbenp.prettier-vscode" \
|
| 126 |
+
"fill-labs.dependi" \
|
| 127 |
+
"formulahendry.auto-close-tag" \
|
| 128 |
+
"formulahendry.auto-rename-tag" \
|
| 129 |
+
"gera2ld.markmap-vscode" \
|
| 130 |
+
"get-snippets.get-snippets" \
|
| 131 |
+
"github.codespaces" \
|
| 132 |
+
"github.copilot" \
|
| 133 |
+
"github.copilot-chat" \
|
| 134 |
+
"github.remotehub" \
|
| 135 |
+
"github.vscode-github-actions" \
|
| 136 |
+
"golang.go" \
|
| 137 |
+
"graphql.vscode-graphql-syntax" \
|
| 138 |
+
"gruntfuggly.todo-tree" \
|
| 139 |
+
"jeff-hykin.better-dockerfile-syntax" \
|
| 140 |
+
"jnoortheen.nix-ide" \
|
| 141 |
+
"justjavac.vscode-deno-extensionpack" \
|
| 142 |
+
"laurencebahiirwa.deno-std-lib-snippets" \
|
| 143 |
+
"lit.lit-snippets" \
|
| 144 |
+
"matthewpi.caddyfile-support" \
|
| 145 |
+
"mechatroner.rainbow-csv" \
|
| 146 |
+
"mhutchie.git-graph" \
|
| 147 |
+
"mirone.milkdown" \
|
| 148 |
+
"misterj.vue-volar-extention-pack" \
|
| 149 |
+
"mkhl.direnv" \
|
| 150 |
+
"mrmlnc.vscode-json5" \
|
| 151 |
+
"ms-dotnettools.csdevkit" \
|
| 152 |
+
"ms-dotnettools.csharp" \
|
| 153 |
+
"ms-dotnettools.vscode-dotnet-runtime" \
|
| 154 |
+
"ms-dotnettools.vscodeintellicode-csharp" \
|
| 155 |
+
"ms-python.black-formatter" \
|
| 156 |
+
"ms-python.debugpy" \
|
| 157 |
+
"ms-python.python" \
|
| 158 |
+
"ms-python.vscode-pylance" \
|
| 159 |
+
"ms-toolsai.jupyter" \
|
| 160 |
+
"ms-toolsai.jupyter-keymap" \
|
| 161 |
+
"ms-toolsai.jupyter-renderers" \
|
| 162 |
+
"ms-toolsai.vscode-jupyter-cell-tags" \
|
| 163 |
+
"ms-toolsai.vscode-jupyter-slideshow" \
|
| 164 |
+
"ms-vscode.azure-repos" \
|
| 165 |
+
"ms-vscode.cmake-tools" \
|
| 166 |
+
"ms-vscode.cpptools" \
|
| 167 |
+
"ms-vscode.cpptools-extension-pack" \
|
| 168 |
+
"ms-vscode.cpptools-themes" \
|
| 169 |
+
"ms-vscode.remote-repositories" \
|
| 170 |
+
"msyrus.go-doc" \
|
| 171 |
+
"njpwerner.autodocstring" \
|
| 172 |
+
"oderwat.indent-rainbow" \
|
| 173 |
+
"pinage404.nix-extension-pack" \
|
| 174 |
+
"redhat.vscode-xml" \
|
| 175 |
+
"redhat.vscode-yaml" \
|
| 176 |
+
"rickyang.ocopilot" \
|
| 177 |
+
"rust-lang.rust-analyzer" \
|
| 178 |
+
"rxliuli.tsx" \
|
| 179 |
+
"saoudrizwan.claude-dev" \
|
| 180 |
+
"sibiraj-s.vscode-scss-formatter" \
|
| 181 |
+
"swellaby.rust-pack" \
|
| 182 |
+
"syler.sass-indented" \
|
| 183 |
+
"tabnine.tabnine-vscode" \
|
| 184 |
+
"tamasfe.even-better-toml" \
|
| 185 |
+
"timonwong.shellcheck" \
|
| 186 |
+
"twxs.cmake" \
|
| 187 |
+
"visualstudioexptteam.intellicode-api-usage-examples" \
|
| 188 |
+
"visualstudioexptteam.vscodeintellicode" \
|
| 189 |
+
"visualstudioexptteam.vscodeintellicode-completions" \
|
| 190 |
+
"vitaliymaz.vscode-svg-previewer" \
|
| 191 |
+
"vitest.explorer" \
|
| 192 |
+
"vue.volar" \
|
| 193 |
+
"wayou.vscode-todo-highlight" \
|
| 194 |
+
) \
|
| 195 |
+
&& for extension in "${extensions[@]}"; do \
|
| 196 |
+
code-server --config /home/mzwing/.config/code-server/config.yaml --install-extension "$extension"; \
|
| 197 |
+
done
|
| 198 |
+
|
| 199 |
+
RUN code-server --config /home/mzwing/.config/code-server/config.yaml --uninstall-extension "serayuzgur.crates"
|
| 200 |
+
|
| 201 |
+
EXPOSE 8080
|
| 202 |
+
|
| 203 |
+
CMD ["code-server", "--config", "/home/mzwing/.config/code-server/config.yaml"]
|