Removed env due to move to base image; updated Dockerfile to include SDKMAN and reflect env changes
This commit is contained in:
@@ -35,9 +35,8 @@ COPY package.json .
|
|||||||
COPY src/* .
|
COPY src/* .
|
||||||
COPY Docker/scripts/run.sh .
|
COPY Docker/scripts/run.sh .
|
||||||
COPY Docker/opt/ /opt/
|
COPY Docker/opt/ /opt/
|
||||||
COPY Docker/env/* /home/abaddon/
|
|
||||||
|
|
||||||
# 4. A: Install dependencies
|
# 4. A: Install system level dependencies
|
||||||
# RUN apt update
|
# RUN apt update
|
||||||
# RUN apt install
|
# RUN apt install
|
||||||
RUN apt-get update
|
RUN apt-get update
|
||||||
@@ -51,11 +50,17 @@ RUN apt-get install -y \
|
|||||||
clangd \
|
clangd \
|
||||||
gopls
|
gopls
|
||||||
|
|
||||||
|
# 4. B: Install SDKMAN
|
||||||
|
USER abaddon
|
||||||
|
RUN curl -fsSL https://get.sdkman.io | bash
|
||||||
|
USER root
|
||||||
|
|
||||||
|
# 4. C: Install pyenv
|
||||||
RUN curl -fsSL https://pyenv.run | bash
|
RUN curl -fsSL https://pyenv.run | bash
|
||||||
RUN pyenv install ${PYTHON_VERSION} && pyenv global ${PYTHON_VERSION} && pyenv local ${PYTHON_VERSION}
|
RUN pyenv install ${PYTHON_VERSION} && pyenv global ${PYTHON_VERSION} && pyenv local ${PYTHON_VERSION}
|
||||||
RUN pip install --no-cache-dir -r requirements.txt
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
|
|
||||||
# 4. B: Install nvm and node
|
# 4. d: Install nvm and node
|
||||||
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v"${NVM_VERSION}"/install.sh | bash
|
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v"${NVM_VERSION}"/install.sh | bash
|
||||||
RUN . "${NVM_DIR}/nvm.sh" && nvm install ${NODE_VERSION}
|
RUN . "${NVM_DIR}/nvm.sh" && nvm install ${NODE_VERSION}
|
||||||
RUN . "${NVM_DIR}/nvm.sh" && nvm use v${NODE_VERSION}
|
RUN . "${NVM_DIR}/nvm.sh" && nvm use v${NODE_VERSION}
|
||||||
|
|||||||
52
Docker/env/.bash_aliases
vendored
52
Docker/env/.bash_aliases
vendored
@@ -1,52 +0,0 @@
|
|||||||
# Aliases
|
|
||||||
|
|
||||||
|
|
||||||
alias ls="ls --block-size=M"
|
|
||||||
alias lsd="ls -d --block-size=M */"
|
|
||||||
alias lines-of-code="cloc --no3 --by-file-by-lang"
|
|
||||||
alias list-biggest-dirs="du -a . | sort -n -r | head -n 50"
|
|
||||||
alias list-biggest-files="find -type f -exec du -Sh {} + | sort -rh | head -n 50"
|
|
||||||
alias fman="compgen -c | fzf | xargs man"
|
|
||||||
|
|
||||||
# Docker
|
|
||||||
alias docker="podman"
|
|
||||||
|
|
||||||
# Archiving
|
|
||||||
alias ltar="tar -ztvf"
|
|
||||||
alias untar="tar -zxvf"
|
|
||||||
alias atar="tar -cvzf"
|
|
||||||
|
|
||||||
# NPM
|
|
||||||
alias npm-list-global='npm list -g --depth 0'
|
|
||||||
alias npm-update-npm='npm install -g npm'
|
|
||||||
alias npm-list-local='npm list --depth 0'
|
|
||||||
|
|
||||||
# Common used command
|
|
||||||
alias wget='wget -c'
|
|
||||||
alias cls='clear'
|
|
||||||
alias less="less -S +G"
|
|
||||||
alias ls="ls -F -h -s --group-directories-first --color=always"
|
|
||||||
alias lt='ls --human-readable --size -1 -S --classify'
|
|
||||||
alias count='find . -type f | wc -l'
|
|
||||||
alias refresh-bash='. ~/.bashrc'
|
|
||||||
alias du="du -h -d 1"
|
|
||||||
alias grep="grep -n -R"
|
|
||||||
|
|
||||||
#gdb no copyright start and use better gui look
|
|
||||||
alias gdb='gdb -tui -q'
|
|
||||||
|
|
||||||
#Git
|
|
||||||
alias gitA="git add -A ."
|
|
||||||
alias gitC="git commit -m"
|
|
||||||
alias gitP="git push"
|
|
||||||
|
|
||||||
# Python
|
|
||||||
alias pySimpleServer='python -m http.server' # Python 3
|
|
||||||
#alias pySimpleServer='python -m SimpleHTTPServer' # Python 2
|
|
||||||
alias pyCgiServer='python -m CGIHTTPServer'
|
|
||||||
alias py-venv='python3 -m venv'
|
|
||||||
alias py-src-activate='source ./bin/activate'
|
|
||||||
alias py-freeze='pip freeze --local > requirements.txt'
|
|
||||||
alias py-upgrade-all='python -m pip list --outdated --format=freeze | grep -v '^\-e' | cut -d = -f 1 | xargs -n1 pip install -U'
|
|
||||||
#alias py-trace='python -m trace --ignore-dir=../lib --trace'
|
|
||||||
#alias py-trace="python -m trace --ignore-dir=$(python -c 'import sys ; print(\":\".join(sys.path)[1:])') --trace"
|
|
||||||
50
Docker/env/.bash_colors
vendored
50
Docker/env/.bash_colors
vendored
@@ -1,50 +0,0 @@
|
|||||||
# Simpler colors in terminal scripts
|
|
||||||
bold=`echo -en "\e[1m"`
|
|
||||||
underline=`echo -en "\e[4m"`
|
|
||||||
dim=`echo -en "\e[2m"`
|
|
||||||
strickthrough=`echo -en "\e[9m"`
|
|
||||||
blink=`echo -en "\e[5m"`
|
|
||||||
reverse=`echo -en "\e[7m"`
|
|
||||||
hidden=`echo -en "\e[8m"`
|
|
||||||
normal=`echo -en "\e[0m"`
|
|
||||||
black=`echo -en "\e[30m"`
|
|
||||||
red=`echo -en "\e[31m"`
|
|
||||||
green=`echo -en "\e[32m"`
|
|
||||||
orange=`echo -en "\e[33m"`
|
|
||||||
blue=`echo -en "\e[34m"`
|
|
||||||
purple=`echo -en "\e[35m"`
|
|
||||||
aqua=`echo -en "\e[36m"`
|
|
||||||
gray=`echo -en "\e[37m"`
|
|
||||||
darkgray=`echo -en "\e[90m"`
|
|
||||||
lightred=`echo -en "\e[91m"`
|
|
||||||
lightgreen=`echo -en "\e[92m"`
|
|
||||||
lightyellow=`echo -en "\e[93m"`
|
|
||||||
lightblue=`echo -en "\e[94m"`
|
|
||||||
lightpurple=`echo -en "\e[95m"`
|
|
||||||
lightaqua=`echo -en "\e[96m"`
|
|
||||||
white=`echo -en "\e[97m"`
|
|
||||||
default=`echo -en "\e[39m"`
|
|
||||||
BLACK=`echo -en "\e[40m"`
|
|
||||||
RED=`echo -en "\e[41m"`
|
|
||||||
GREEN=`echo -en "\e[42m"`
|
|
||||||
ORANGE=`echo -en "\e[43m"`
|
|
||||||
BLUE=`echo -en "\e[44m"`
|
|
||||||
PURPLE=`echo -en "\e[45m"`
|
|
||||||
AQUA=`echo -en "\e[46m"`
|
|
||||||
GRAY=`echo -en "\e[47m"`
|
|
||||||
DARKGRAY=`echo -en "\e[100m"`
|
|
||||||
LIGHTRED=`echo -en "\e[101m"`
|
|
||||||
LIGHTGREEN=`echo -en "\e[102m"`
|
|
||||||
LIGHTYELLOW=`echo -en "\e[103m"`
|
|
||||||
LIGHTBLUE=`echo -en "\e[104m"`
|
|
||||||
LIGHTPURPLE=`echo -en "\e[105m"`
|
|
||||||
LIGHTAQUA=`echo -en "\e[106m"`
|
|
||||||
WHITE=`echo -en "\e[107m"`
|
|
||||||
DEFAULT=`echo -en "\e[49m"`
|
|
||||||
export LESS_TERMCAP_so=${white}${BLACK} # begin standout-mode - info box
|
|
||||||
export LESS_TERMCAP_mb=${lightred} # begin blinking
|
|
||||||
export LESS_TERMCAP_md=${lightyellow} # begin bold
|
|
||||||
export LESS_TERMCAP_us=${lightgreen} # begin underline
|
|
||||||
export LESS_TERMCAP_me=${default}${DEFAULT} # end mode
|
|
||||||
export LESS_TERMCAP_se=${default}${DEFAULT} # end standout-mode
|
|
||||||
export LESS_TERMCAP_ue=${default}${DEFAULT} # end underline
|
|
||||||
24
Docker/env/.bash_exports
vendored
24
Docker/env/.bash_exports
vendored
@@ -1,24 +0,0 @@
|
|||||||
# Python
|
|
||||||
export PYTHONDONTWRITEBYTECODE=1
|
|
||||||
|
|
||||||
|
|
||||||
# Launchpad Config Parts
|
|
||||||
export DEBFULLNAME="Maxim Stewart"
|
|
||||||
export DEBEMAIL="1itdominator@gmail.com"
|
|
||||||
|
|
||||||
|
|
||||||
shopt -s cdspell
|
|
||||||
shopt -s autocd shift_verbose
|
|
||||||
shopt -s dirspell
|
|
||||||
|
|
||||||
|
|
||||||
# Bash history settings
|
|
||||||
export HISTSIZE=3000
|
|
||||||
export HISTCONTROL=$HISTCONTROL:ignoredups
|
|
||||||
|
|
||||||
# Default Editor
|
|
||||||
export EDITOR=nano
|
|
||||||
|
|
||||||
# Default FZF
|
|
||||||
# Note: bat is cat but with colors
|
|
||||||
export FZF_DEFAULT_OPTS="--layout=reverse --height=100% --preview='bat -p --color=always {}'"
|
|
||||||
48
Docker/env/.bash_functions
vendored
48
Docker/env/.bash_functions
vendored
@@ -1,48 +0,0 @@
|
|||||||
# Functions
|
|
||||||
|
|
||||||
|
|
||||||
# Python based scripts
|
|
||||||
|
|
||||||
function py-trace() {
|
|
||||||
python -m trace --ignore-dir=$(python -c 'import sys ; print(":".join(sys.path)[1:])') --trace "$@"
|
|
||||||
}
|
|
||||||
|
|
||||||
# Everything else
|
|
||||||
|
|
||||||
function git-branch() {
|
|
||||||
branch=`git branch | fzf | xargs`
|
|
||||||
git checkout "${branch}"
|
|
||||||
}
|
|
||||||
|
|
||||||
function ex() {
|
|
||||||
if [ -f $1 ]; then
|
|
||||||
case $1 in
|
|
||||||
*.tar.bz2) tar xjf $1 ;;
|
|
||||||
*.tar.gz) tar xzf $1 ;;
|
|
||||||
*.bz2) bunzip2 $1 ;;
|
|
||||||
*.rar) unrar x $1 ;;
|
|
||||||
*.gz) gunzip $1 ;;
|
|
||||||
*.tar) tar xf $1 ;;
|
|
||||||
*.tbz2) tar xjf $1 ;;
|
|
||||||
*.tgz) tar xzf $1 ;;
|
|
||||||
*.zip) unzip $1 ;;
|
|
||||||
*.Z) uncompress $1 ;;
|
|
||||||
*.7z) 7z x $1 ;;
|
|
||||||
*.deb) ar x $1 ;;
|
|
||||||
*.tar.xz) tar xf $1 ;;
|
|
||||||
*.tar.zst) tar xf $1 ;;
|
|
||||||
*) echo "'$1' cannot be extracted using ex()" ;;
|
|
||||||
esac
|
|
||||||
else
|
|
||||||
echo "'$1' is not a valid file"
|
|
||||||
fi
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
function php-server() {
|
|
||||||
if [ $1 <= 1024 ]; then
|
|
||||||
authbind php -S 0.0.0.0:"$1"
|
|
||||||
else
|
|
||||||
php -S 0.0.0.0:"$1"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
17
Docker/env/.bash_ps1
vendored
17
Docker/env/.bash_ps1
vendored
@@ -1,17 +0,0 @@
|
|||||||
#sysInfo="$(screenfetch)"
|
|
||||||
#export PS1="${sysInfo}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
function prompt_command() {
|
|
||||||
_COMMAND="parts = '$(pwd)'.split('/'); print('$(pwd)') if not len(parts) > 3 else print(f'.../{parts[-3]}/{parts[-2]}/{parts[-1]}')"
|
|
||||||
_PATH=$(python <<< "${_COMMAND}" || pwd)
|
|
||||||
_BRANCH="$(git rev-parse --symbolic-full-name --abbrev-ref HEAD 2>/dev/null)"
|
|
||||||
|
|
||||||
# Week Day/Month/Day : Time -- user@group -- current dir path -- git branch
|
|
||||||
PS1="\[\e[32m\]\d\[\e[m\]: \[\e[36m\]\@\[\e[m\] -- \[\e[31m\]\u\[\e[m\]@\[\e[31m\]\h\[\e[m\] -- \[\e[35m\]${_PATH}\[\e[m\] -- ${_BRANCH} \\$ "
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
export PROMPT_COMMAND=prompt_command
|
|
||||||
42
Docker/env/.bashrc
vendored
42
Docker/env/.bashrc
vendored
@@ -1,42 +0,0 @@
|
|||||||
# Colors
|
|
||||||
if [ -e $HOME/.bash_colors ]; then
|
|
||||||
source $HOME/.bash_colors
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Exports Variable Settings
|
|
||||||
if [ -e $HOME/.bash_exports ]; then
|
|
||||||
source $HOME/.bash_exports
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Paths
|
|
||||||
if [ -e $HOME/.bash_paths ]; then
|
|
||||||
source $HOME/.bash_paths
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -e $HOME/.bash_ld_library_path ]; then
|
|
||||||
source $HOME/.bash_ld_library_path
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Aliases
|
|
||||||
if [ -e $HOME/.bash_aliases ]; then
|
|
||||||
source $HOME/.bash_aliases
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Functions
|
|
||||||
if [ -e $HOME/.bash_functions ]; then
|
|
||||||
source $HOME/.bash_functions
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Auto complete -- Note: Must have bash-completion package
|
|
||||||
if [ -f /etc/bash_completion ]; then
|
|
||||||
. /etc/bash_completion
|
|
||||||
fi
|
|
||||||
|
|
||||||
[ -f ~/.fzf.bash ] && source ~/.fzf.bash
|
|
||||||
|
|
||||||
|
|
||||||
# Terminal look and feel with logo and then custom prompt line
|
|
||||||
echo "${lightred}Welcome to the dark side of the moon, $(whoami)!${default}"
|
|
||||||
if [ -e $HOME/.bash_ps1 ]; then
|
|
||||||
source $HOME/.bash_ps1
|
|
||||||
fi
|
|
||||||
8
Docker/env/.gitconfig
vendored
8
Docker/env/.gitconfig
vendored
@@ -1,8 +0,0 @@
|
|||||||
[user]
|
|
||||||
email = 1itdominator@gmail.com
|
|
||||||
name = itdominator
|
|
||||||
[filter "lfs"]
|
|
||||||
clean = git-lfs clean -- %f
|
|
||||||
smudge = git-lfs smudge -- %f
|
|
||||||
process = git-lfs filter-process
|
|
||||||
required = true
|
|
||||||
Reference in New Issue
Block a user