add individual install scripts
ci/woodpecker/push/test Pipeline was successful Details
ci/woodpecker/push/master Pipeline was successful Details
ci/woodpecker/push/next Pipeline was successful Details
ci/woodpecker/pr/test Pipeline was successful Details
ci/woodpecker/pr/master Pipeline was successful Details
ci/woodpecker/pr/next Pipeline was successful Details

This commit is contained in:
OCram85 2022-11-04 11:50:01 +01:00
parent 2a8a953f0d
commit d84a3b7e6e
5 changed files with 72 additions and 17 deletions

View File

@ -14,21 +14,7 @@ RUN \
git config --system credential.helper store && \
echo 'source /usr/share/bash-completion/completions/git' >> /etc/bash.bashrc
#RUN \
# echo "**** install dev runtimes ****" && \
# curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash - && \
# apt-get install --no-install-recommends -y \
# nodejs \
# golang-go
#RUN \
# echo "**** clean up ****" && \
# apt-get clean && \
# rm -rf \
# /tmp/* \
# /var/lib/apt/lists/* \
# /var/tmp/*
ADD finalize-codeserver.sh /usr/bin/
ADD install/install* /usr/bin/
RUN \
chmod +x /usr/bin/finalize-codeserver.sh
chmod +x /usr/bin/install-* && \
echo "Install required dev runtimes with the 'install-*' scripts." >> /etc/bashrc

12
install/install-dotnet.sh Normal file
View File

@ -0,0 +1,12 @@
#!/bin/bash
set -e
echo "**** downloading latest install script ****"
curl -fsSL https://dot.net/v1/dotnet-install.sh -o /tmp/dotnet-install.sh
chmod +x /tmp/dotnet-install.sh
echo "**** installing latest .NET Core LTS release ****"
/tmp/dotnet-install.sh --channel LTS
echo 'export PATH=$PATH:/config/.dotnet' | sudo tee -a /etc/bash.bashrc > /dev/null
echo "**** done. ****"

19
install/install-golang.sh Normal file
View File

@ -0,0 +1,19 @@
#!/bin/bash
set -e
if [[ -z "$1" ]]
then
GOVERSION="1.19.3"
else
GOVERSION="$1"
fi
echo "**** downloading golang ($GOVERSION)****"
curl -fsSL "https://go.dev/dl/go$GOVERSION.linux-amd64.tar.gz" -o /tmp/golang.tar.gz
echo "**** installing golang ($GOVERSION)****"
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf /tmp/golang.tar.gz
echo 'export PATH=$PATH:/usr/local/go/bin' | sudo tee -a /etc/bash.bashrc > /dev/null
echo "**** cleaning up ****"
rm -f /tmp/golang.tar.gz
echo "**** done. ****"
echo "**** please reload bashprofile to finalize ****"

17
install/install-nodejs.sh Normal file
View File

@ -0,0 +1,17 @@
#!/bin/bash
set -e
echo "**** adding nodesource package source (NodeJS LTS) ****"
curl -fsSL https://deb.nodesource.com/setup_lts.x | sudo -E bash -
echo "**** updating package lists + installing NodeJS LTS ****"
sudo apt-get install --no-install-recommends -y \
nodejs
echo "**** cleaning up ****"
sudo apt-get clean
sudo rm -rf \
/tmp/* \
/var/lib/apt/lists/* \
/var/tmp/*
echo "**** done. ****"

View File

@ -0,0 +1,21 @@
#!/bin/bash
set -e
echo "**** installing powershell requirements ****"
sudo apt-get install --no-install-recommends -y \
apt-transport-https \
software-properties-common
echo "**** adding powershell package sources ****"
# Download the Microsoft repository GPG keys
curl -fsSL "https://packages.microsoft.com/config/ubuntu/$(lsb_release -rs)/packages-microsoft-prod.deb" -o /tmp/packages-microsoft-prod.deb
# Register the Microsoft repository GPG keys
sudo dpkg -i /tmp/packages-microsoft-prod.deb
# Update the list of packages after we added packages.microsoft.com
sudo apt-get update
echo "**** installing powershell ****"
# Install PowerShell
sudo apt-get install --no-install-recommends -y powershell
echo "**** done. ****"
# Start PowerShell
#pwsh