Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 78 lines (74 sloc) 3.646 kB
df1fb37 @gholms Update GPL file headers
gholms authored
1 # Copyright 2009-2012 Eucalyptus Systems, Inc.
2 #
3 # This program is free software: you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation; version 3 of the License.
6 #
7 # This program is distributed in the hope that it will be useful,
8 # but WITHOUT ANY WARRANTY; without even the implied warranty of
9 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 # GNU General Public License for more details.
11 #
12 # You should have received a copy of the GNU General Public License
13 # along with this program. If not, see http://www.gnu.org/licenses/.
be2fb89 modified setup_db.groovy and added bash aliases so you can use postgr…
Tom Werges authored
14 #
df1fb37 @gholms Update GPL file headers
gholms authored
15 # Please contact Eucalyptus Systems, Inc., 6755 Hollister Ave., Goleta
16 # CA 93117, USA or visit http://www.eucalyptus.com/licenses/ if you need
17 # additional information or have any questions.
47b5fb5 @gholms Tweak GPL headers
gholms authored
18 #
19 # This file may incorporate work covered under the following copyright
20 # and permission notice:
21 #
22 # Software License Agreement (BSD License)
23 #
24 # Copyright (c) 2008, Regents of the University of California
25 # All rights reserved.
26 #
27 # Redistribution and use of this software in source and binary forms,
28 # with or without modification, are permitted provided that the
29 # following conditions are met:
30 #
31 # Redistributions of source code must retain the above copyright
32 # notice, this list of conditions and the following disclaimer.
33 #
34 # Redistributions in binary form must reproduce the above copyright
35 # notice, this list of conditions and the following disclaimer
36 # in the documentation and/or other materials provided with the
37 # distribution.
38 #
39 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
40 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
41 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
42 # FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
43 # COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
44 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
45 # BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
46 # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
47 # CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
48 # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
49 # ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
50 # POSSIBILITY OF SUCH DAMAGE. USERS OF THIS SOFTWARE ACKNOWLEDGE
51 # THE POSSIBLE PRESENCE OF OTHER OPEN SOURCE LICENSED MATERIAL,
52 # COPYRIGHTED MATERIAL OR PATENTED MATERIAL IN THIS SOFTWARE,
53 # AND IF ANY SUCH MATERIAL IS DISCOVERED THE PARTY DISCOVERING
54 # IT MAY INFORM DR. RICH WOLSKI AT THE UNIVERSITY OF CALIFORNIA,
55 # SANTA BARBARA WHO WILL THEN ASCERTAIN THE MOST APPROPRIATE REMEDY,
56 # WHICH IN THE REGENTS' DISCRETION MAY INCLUDE, WITHOUT LIMITATION,
57 # REPLACEMENT OF THE CODE SO IDENTIFIED, LICENSING OF THE CODE SO
58 # IDENTIFIED, OR WITHDRAWAL OF THE CODE CAPABILITY TO THE EXTENT
59 # NEEDED TO COMPLY WITH ANY SUCH LICENSES OR RIGHTS.
df1fb37 @gholms Update GPL file headers
gholms authored
60
be2fb89 modified setup_db.groovy and added bash aliases so you can use postgr…
Tom Werges authored
61 # This script allows you to run postgres CLI tools such as "psql"
62 # without providing authorization or connection parameters, provided
63 # you are root. After SOURCING this script, you should be able to run
64 # "psql -d database" as root. No further auth is required.
65 #
66 # NOTE: This file must be SOURCED, not executed: ". aliases.sh"
67
68 if [ -z "$EUCALYPTUS" ]; then
69 echo "EUCALYPTUS must be set"
70 else
71 DATA_DIR=$EUCALYPTUS/var/lib/eucalyptus/db/data/
72 PORT=8777
73
74 alias psql="psql -h $DATA_DIR -p $PORT"
75 alias pg_dump="pg_dump -h $DATA_DIR -p $PORT"
76 alias pg_restore="pg_restore -h $DATA_DIR -p $PORT"
77 fi
Something went wrong with that request. Please try again.