bug 376046 - add support for specifying an ssh private key in the symbol upload script - bash-fu + a bonus fix that i missed in a previous patch. r=bsmedberg
authorted.mielczarek@gmail.com
Wed, 04 Apr 2007 11:47:44 -0700
changeset 342 4218503d8f358e6a0b292c11b8e72a3d991c2ba5
parent 341 0fefaac9aaa72d5462d63192e7ceac7fbf9f2d78
child 343 bf97cd21864149bef87fccbc978f29c1625b05d4
push id1
push userbsmedberg@mozilla.com
push dateThu, 20 Mar 2008 16:49:24 +0000
treeherdermozilla-central@61007906a1f8 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbsmedberg
bugs376046
milestone1.9a4pre
bug 376046 - add support for specifying an ssh private key in the symbol upload script - bash-fu + a bonus fix that i missed in a previous patch. r=bsmedberg
Makefile.in
toolkit/airbag/tools/upload_symbols.sh
--- a/Makefile.in
+++ b/Makefile.in
@@ -153,17 +153,17 @@ ifdef MOZ_AIRBAG
 	mv $(DIST)/crashreporter-symbols/crashreporter-symbols-$(BUILDID).zip \
           $(topsrcdir)/../$(BUILDID)
 endif # MOZ_DEBUG_SYMBOLS
 endif # MOZ_AIRBAG
 
 uploadsymbols:
 ifdef MOZ_DEBUG_SYMBOLS
 ifdef MOZ_AIRBAG
-	$(topsrcdir)/toolkit/airbag/tools/upload_symbols.sh $(topsrcdir)/../$(BUILDID)/airbag-symbols-$(BUILDID).zip
+	$(topsrcdir)/toolkit/airbag/tools/upload_symbols.sh $(topsrcdir)/../$(BUILDID)/crashreporter-symbols-$(BUILDID).zip
 endif
 endif
 
 ## XXXvlad -- the test and cp should be removed once bug 249782 is
 ## completely fixed
 signnss:
 ifdef MOZILLA_OFFICIAL
 	echo signing NSS libs
--- a/toolkit/airbag/tools/upload_symbols.sh
+++ b/toolkit/airbag/tools/upload_symbols.sh
@@ -1,9 +1,9 @@
-#!/bin/sh
+#!/bin/bash
 #
 # ***** BEGIN LICENSE BLOCK *****
 # Version: MPL 1.1/GPL 2.0/LGPL 2.1
 #
 # The contents of this file are subject to the Mozilla Public License Version
 # 1.1 (the "License"); you may not use this file except in compliance with
 # the License. You may obtain a copy of the License at
 # http://www.mozilla.org/MPL/
@@ -44,18 +44,18 @@
 # And will use the following optional environment variable if set:
 # SYMBOL_SERVER_SSH_KEY : path to a ssh private key to use
 #
 set -e
 
 : ${SYMBOL_SERVER_HOST?} ${SYMBOL_SERVER_USER?} ${SYMBOL_SERVER_PATH?} ${1?"You must specify a symbol archive to upload"}
 archive=`basename $1`
 echo "Transferring symbols... $1"
-scp -v ${SYMBOL_SERVER_SSH_KEY:-i $SYMBOL_SERVER_SSH_KEY} $1 \
+scp -v ${SYMBOL_SERVER_SSH_KEY:+-i $SYMBOL_SERVER_SSH_KEY} $1 \
   ${SYMBOL_SERVER_USER}@${SYMBOL_SERVER_HOST}:${SYMBOL_SERVER_PATH}/
 echo "Unpacking symbols on remote host..."
-ssh -2 ${SYMBOL_SERVER_SSH_KEY:-i $SYMBOL_SERVER_SSH_KEY} \
+ssh -2 ${SYMBOL_SERVER_SSH_KEY:+-i $SYMBOL_SERVER_SSH_KEY} \
   -l ${SYMBOL_SERVER_USER} ${SYMBOL_SERVER_HOST} \
   "set -e;
    cd ${SYMBOL_SERVER_PATH};
    unzip $archive;
    rm -v $archive;"
 echo "Symbol transfer completed"