| garciadeblas | 93c6131 | 2016-09-28 15:12:48 +0200 | [diff] [blame] | 1 | #!/bin/bash |
| garciadeblas | d8bc5c3 | 2018-05-09 17:37:56 +0200 | [diff] [blame] | 2 | REPOSITORY_BASE=https://osm-download.etsi.org/repository/osm/debian |
| 3 | RELEASE=ReleaseFOUR |
| garciadeblas | e990f66 | 2018-05-18 11:43:39 +0200 | [diff] [blame] | 4 | REPOSITORY=stable |
| garciadeblas | 93c6131 | 2016-09-28 15:12:48 +0200 | [diff] [blame] | 5 | |
| garciadeblas | d8bc5c3 | 2018-05-09 17:37:56 +0200 | [diff] [blame] | 6 | add_repo() { |
| 7 | REPO_CHECK="^$1" |
| 8 | grep "${REPO_CHECK/\[arch=amd64\]/\\[arch=amd64\\]}" /etc/apt/sources.list > /dev/null 2>&1 |
| 9 | if [ $? -ne 0 ] |
| 10 | then |
| 11 | wget -qO - $REPOSITORY_BASE/$RELEASE/OSM%20ETSI%20Release%20Key.gpg | sudo apt-key add - |
| 12 | sudo DEBIAN_FRONTEND=noninteractive add-apt-repository -y "$1" && sudo DEBIAN_FRONTEND=noninteractive apt-get update |
| garciadeblas | 429b9f8 | 2018-03-20 02:09:44 +0100 | [diff] [blame] | 13 | return 0 |
| garciadeblas | d8bc5c3 | 2018-05-09 17:37:56 +0200 | [diff] [blame] | 14 | fi |
| 15 | |
| 16 | return 1 |
| garciadeblas | 55490d4 | 2016-10-29 14:22:03 +0200 | [diff] [blame] | 17 | } |
| 18 | |
| garciadeblas | d8bc5c3 | 2018-05-09 17:37:56 +0200 | [diff] [blame] | 19 | add_repo "deb [arch=amd64] $REPOSITORY_BASE/$RELEASE $REPOSITORY devops" |
| garciadeblas | 35f96ae | 2018-05-23 12:33:36 +0200 | [diff] [blame] | 20 | sudo DEBIAN_FRONTEND=noninteractive apt-get -q update |
| 21 | sudo DEBIAN_FRONTEND=noninteractive apt-get install osm-devops |
| garciadeblas | d8bc5c3 | 2018-05-09 17:37:56 +0200 | [diff] [blame] | 22 | /usr/share/osm-devops/installers/full_install_osm.sh -R $RELEASE -r $REPOSITORY -D /usr/share/osm-devops "$@" |