| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | # |
| 3 | # Copyright 2016 Telefónica Investigación y Desarrollo, S.A.U. |
| 4 | # |
| 5 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | # you may not use this file except in compliance with the License. |
| 7 | # You may obtain a copy of the License at |
| 8 | # |
| 9 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | # |
| 11 | # Unless required by applicable law or agreed to in writing, software |
| 12 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
| 16 | # |
| 17 | # Authors: |
| 18 | # - Gerardo Garcia - gerardo.garciadeblas@telefonica.com |
| 19 | # |
| 20 | |
| 21 | HERE=$(realpath $(dirname $0)) |
| 22 | OSM_JENKINS=$(dirname $HERE) |
| 23 | . $OSM_JENKINS/common/all_funcs |
| 24 | |
| 25 | # SET YOUR MDG repository name here |
| 26 | export OSM_MDG=RO |
| 27 | OSM_load_config |
| 28 | |
| Mike Marchetti | 425f8ce | 2017-06-15 13:02:16 -0400 | [diff] [blame] | 29 | . $OSM_JENKINS/common/install_common |
| 30 | |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 31 | # Installation starts here |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 32 | |
| 33 | #Release TWO |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 34 | |
| garciadeblas | 24aaf3e | 2017-10-04 11:08:28 +0200 | [diff] [blame] | 35 | DEBIAN_FRONTEND=noninteractive add-apt-repository -y cloud-archive:ocata |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 36 | apt-get update |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 37 | apt-get -y install python-osm-ro |
| 38 | |
| garciadeblas | d969d9c | 2017-09-21 12:04:11 +0200 | [diff] [blame] | 39 | OSMIM_PATH=`python -c 'import osm_im; print osm_im.__path__[0]'` || FATAL "python-osm-im was not properly installed" |
| 40 | OSMLIBOVIM_PATH=`python -c 'import lib_osm_openvim; print lib_osm_openvim.__path__[0]'` || FATAL "python-lib-osm-openvim was not properly installed" |
| 41 | OSMRO_PATH=`python -c 'import osm_ro; print osm_ro.__path__[0]'` || FATAL "python-osm-ro was not properly installed" |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 42 | |
| Mike Marchetti | 86def78 | 2017-07-26 15:20:11 -0400 | [diff] [blame] | 43 | DEBIAN_FRONTEND=noninteractive ${OSMRO_PATH}/database_utils/install-db-server.sh --updatedb || FATAL "osm-ro db installation failed" |
| 44 | DEBIAN_FRONTEND=noninteractive ${OSMLIBOVIM_PATH}/database_utils/install-db-server.sh -u mano -p manopw -d mano_vim_db --updatedb || FATAL "lib-osm-openvim db installation failed" |
| garciadeblas | a1fc457 | 2017-04-24 19:08:21 +0200 | [diff] [blame] | 45 | service osm-ro restart |
| 46 | |
| 47 | RC=$? |
| 48 | INFO "done, RC=$RC" |
| 49 | exit $RC |
| 50 | |
| 51 | |