File tree Expand file tree Collapse file tree 3 files changed +23
-39
lines changed
Expand file tree Collapse file tree 3 files changed +23
-39
lines changed Original file line number Diff line number Diff line change 2424 /tmp/* \
2525 /var/tmp/*
2626
27- COPY bashrc /workspace/.bashrc
28-
2927EXPOSE 8080
3028
3129ENTRYPOINT [ "/app/code-server/run.sh" ]
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11#! /bin/bash
22
3+ # set defaults for env vars
34export HOME=" /workspace"
45LOCALE=" ${LOCALE:- en} "
56PASSWORD=" ${PASSWORD:- changeit} "
6- EXTENSIONS=" ${EXTENSIONS:- golang.go|ms-python.python|ms-python.debugpy|eamodio.gitlens|humao.rest-client|esbenp.prettier-vscode|dbaeumer.vscode-eslint|ecmel.vscode-html-css|pkief.material-icon-theme|k--kato.intellij-idea-keybindings } "
7+ EXTENSIONS=" ${EXTENSIONS:- golang.go|ms-python.python|ms-python.debugpy|eamodio.gitlens|humao.rest-client|esbenp.prettier-vscode|dbaeumer.vscode-eslint|ecmel.vscode-html-css|pkief.material-icon-theme} "
78
9+ # update system
810dnf update -y
911
12+ # create .bashrc
13+ cat > /workspace/.bashrc << EOL
14+ if [ -f /etc/bashrc ]; then
15+ . /etc/bashrc
16+ fi
17+ unset rc
18+
19+ alias cd..='cd ..'
20+
21+ function parse_git_dirty {
22+ [[ \$ (git status --porcelain 2> /dev/null) ]] && echo "*"
23+ }
24+ function parse_git_branch {
25+ git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/ (\1\$ (parse_git_dirty))/"
26+ }
27+ export PS1="\t \[\033[32m\]\w\[\033[33m\]\\\$ (parse_git_branch)\[\033[00m\] \$ "
28+ EOL
29+
30+ # install vs-code extensions
1031/app/code-server/bin/code-server --install-extension ${EXTENSIONS// |/ --install-extension }
32+ # run code-server
1133/app/code-server/bin/code-server --disable-telemetry --disable-workspace-trust --locale ${LOCALE} --bind-addr 0.0.0.0:8080
You can’t perform that action at this time.
0 commit comments