Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

README, argument checking and help messages issues.

  • Loading branch information...
commit 12ec9931dcba416ffaec7dc0ffcf8cc089e45559 1 parent 62a7b4e
leamas authored December 13, 2010
3  fedora/diaspora-thin.conf
@@ -2,6 +2,9 @@
2 2
 
3 3
 stop on runlevel [06]
4 4
 
  5
+pre-start exec pkill -fu diaspora thin
  6
+post-stop exec pkill -fu diaspora thin
  7
+
5 8
 script
6 9
   if [ -f /etc/default/diaspora ]; then
7 10
     . /etc/default/diaspora;
2  fedora14-setup.bash
@@ -118,7 +118,7 @@ else
118 118
 fi
119 119
 
120 120
 echo 'To start server: sudo su - diaspora -c "diaspora/script/server -d"'
121  
-echo " To stop server: pkill thin; kill \$(cat $pidfile)"
  121
+echo " To stop server: pkill thin; kill \\\$(cat $pidfile)"
122 122
 
123 123
 EOF
124 124
 
2  source/funcs.sh
@@ -155,7 +155,7 @@ function init_db
155 155
 {
156 156
     [ -n "$1" ] && pw_arg="password=$1"
157 157
     if bundle exec rake db:first_user $pw_arg; then
158  
-        echo "Database config OK, first user setup."
  158
+        echo "Database config OK."
159 159
         return
160 160
     else
161 161
         return  1
23  ubuntu/README.md
Source Rendered
@@ -13,19 +13,30 @@ Bootstrap the distribution from git:
13 13
 
14 14
 Create and install the diaspora bundle and application in
15 15
 diaspora/pkg/source according to
16  
-[source README](http://github.com/diaspora/diaspora-packages/tree/master/source/)
  16
+[source README]
  17
+(http://github.com/diaspora/diaspora-packages/tree/master/source/):
  18
+    % cd pkg/source
  19
+    % ./make-dist.sh bundle
  20
+    % ./make-dist.sh source
17 21
 
18 22
 Install the dependencies (a good time for a coffe break):
19 23
     % cd pkg/ubuntu
20 24
     % sudo ./diaspora-install-deps
21 25
 
22  
-Install, initiate and start the server;
23  
-    % sudo ./diaspora-install
  26
+Install and  initiate the tarballs created bt make-dist.sh:
  27
+    % sudo ./diaspora-install-bundle \
  28
+        dist/diaspora-bundle-rt-0.0-xxxx_yyyy.tar.gz
  29
+    % sudo ./diaspora-install dist/diaspora-0.0-xxxx_yyyy.tar.gz
24 30
     % sudo ./diaspora-setup
25 31
     % sudo su - diaspora
26 32
     % cd /usr/share/diaspora/master
  33
+
  34
+Start the development server
27 35
     % ./script/server
28 36
 
  37
+Start servers
  38
+    % sudo service diaspora start
  39
+
29 40
 ### Upgrading
30 41
 
31 42
 The normal procedure to update is to just
@@ -41,15 +52,13 @@ In most cases only source will need to be built, which is fast.
41 52
 
42 53
 ### Notes
43 54
 
44  
-The diaspora services are controlled by upstart. To start/stop:
  55
+The diaspora services are controlled by upstart. To start/stop
  56
+individual services:
45 57
     % sudo initctl <start|stop|status>  diaspora-thin
46 58
     % sudo initctl <start|stop|status>  diaspora-redis
47 59
     % sudo initctl <start|stop|status>  diaspora-websocket
48 60
     % sudo initctl <start|stop|status>  diaspora-resque
49 61
 
50  
-To start/stop all services:
51  
-    % sudo service diaspora <start|stop|status>
52  
-
53 62
 The application lives in /usr/share/diaspora/master. All writable areas
54 63
 (log, uploads, tmp) are links to /var/lib/diaspora. The config file lives
55 64
 in /etc/diaspora. All files in /usr/share are read-only, owned by root.
14  ubuntu/diaspora-bundle-install
... ...
@@ -1,19 +1,17 @@
1 1
 #!/bin/sh
  2
+#
  3
+# Install  an ubuntu bundle package.
  4
+#
  5
+Usage='diaspora-bundle-install <diaspora-bundle-VERSION-RELEASE.tar.gz'
2 6
 
3 7
 test "$(perl -e 'print $>')" = "0" || {
4 8
     echo "You need to be root to do this, giving up"
5 9
     exit 2
6 10
 }
7 11
 
8  
-test $# = "1" || {
9  
-    echo "Usage: diaspora-bundle-install <diaspora-bundle-VERSION-RELEASE.tar.gz>"
10  
-    exit 1
11  
-}
  12
+test $# -eq 1 || { echo $Usage; exit 2; }
12 13
 
13  
-test -r "$1" || {
14  
-    echo "Cannot open $1"
15  
-    exit 2
16  
-}
  14
+test -r "$1" || { echo "Cannot open $1" exit 2; }
17 15
 
18 16
 rm -rf /usr/lib/diaspora-bundle
19 17
 tar xzf $1 -C /usr/lib
7  ubuntu/diaspora-install
@@ -2,13 +2,18 @@
2 2
 #
3 3
 # Install a fedora source package
4 4
 #
5  
-# Usage diaspora-install <tar package>
  5
+#
  6
+Usage='diaspora-install <tar package>'
6 7
 
7 8
 test "$(perl -e 'print $>')" = "0" || {
8 9
     echo "You need to be root to do this, giving up"
9 10
     exit 2
10 11
 }
11 12
 
  13
+test  $# -eq 1 || { echo "$Usage"; exit 2; }
  14
+
  15
+test -r "$1" || { echo "Cannot open $1"; exit 2;  }
  16
+
12 17
 getent group diaspora >/dev/null || groupadd -r diaspora
13 18
 getent passwd diaspora >/dev/null ||    \
14 19
     useradd -r -g diaspora              \

0 notes on commit 12ec993

Please sign in to comment.
Something went wrong with that request. Please try again.