summaryrefslogtreecommitdiff
path: root/scripts/setup_publish_keys.sh
blob: b363d9d321349754022f1843a72e48cf866ca8dc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/bash

set -e

if [[ -n $GOOGLE_KEY ]]; then
  echo $GOOGLE_KEY | base64 -d > key.json
fi
if [[ -n $KEY ]]; then
  wget "https://github.com/navit-gps/infrastructure-blackbox/raw/master/keyrings/keystore.gpg"
  openssl aes-256-cbc -d -in keystore.gpg -md md5 -k $KEY > keystore
  keytool -importkeystore -srcstorepass "$STORE_PASS" -deststorepass "$STORE_PASS" -srckeystore keystore -destkeystore ~/.keystore -deststoretype pkcs12
  rm keystore.gpg keystore
fi