mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-20 06:29:50 +00:00
19 lines
914 B
Bash
19 lines
914 B
Bash
#!/bin/bash
|
|
################################################################################
|
|
## File: repos.sh
|
|
## Desc: Installs official Microsoft package repos for the distribution
|
|
################################################################################
|
|
|
|
LSB_RELEASE=$(lsb_release -rs)
|
|
|
|
# Install Microsoft repository
|
|
wget https://packages.microsoft.com/config/ubuntu/$LSB_RELEASE/packages-microsoft-prod.deb
|
|
dpkg -i packages-microsoft-prod.deb
|
|
apt-get install -y apt-transport-https
|
|
|
|
# Install Microsoft GPG public key
|
|
curl -L https://packages.microsoft.com/keys/microsoft.asc | apt-key add -
|
|
curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
|
|
mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg
|
|
sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-bionic-prod bionic main" > /etc/apt/sources.list.d/dotnetdev.list'
|
|
apt-get update |