alpha_omega 1.1.1 → 1.1.3
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/bin/alpha_omega +2 -10
- data/lib/alpha_omega/deploy.rb +2 -16
- data/libexec/ao +15 -0
- data/libexec/ao-activate +22 -0
- data/libexec/ao-build +22 -0
- data/libexec/ao-check +22 -0
- data/libexec/ao-compare +22 -0
- data/libexec/ao-cook +22 -0
- data/libexec/ao-deploy +22 -0
- data/libexec/ao-dist +22 -0
- data/libexec/ao-lock +31 -0
- data/libexec/ao-migrate +22 -0
- data/libexec/ao-plan +22 -0
- data/libexec/ao-release +22 -0
- data/libexec/ao-restart +22 -0
- data/libexec/ao-rollback +22 -0
- data/libexec/ao-shell +22 -0
- data/libexec/ao-stage +22 -0
- data/libexec/ao-task +23 -0
- data/libexec/ao-unlock +31 -0
- data/sbin/_bump +126 -0
- data/sbin/_jason +172 -0
- data/sbin/_log4sh +3840 -0
- data/sbin/_meat +172 -0
- data/sbin/_prime +8 -0
- data/sbin/_shflags +1012 -0
- data/sbin/_shunit +1048 -0
- data/sbin/_sub +37 -0
- data/sbin/_treadstone +8 -0
- data/sbin/_versions +174 -0
- data/sbin/ao +15 -0
- data/sbin/stub +15 -0
- metadata +31 -57
- data/libexec/activate +0 -199
- data/libexec/build +0 -30
- data/libexec/build.orig +0 -199
- data/libexec/bump.orig +0 -32
- data/libexec/check +0 -199
- data/libexec/compare +0 -199
- data/libexec/config +0 -199
- data/libexec/debug +0 -199
- data/libexec/deploy +0 -199
- data/libexec/dist +0 -199
- data/libexec/dna +0 -199
- data/libexec/hosts +0 -199
- data/libexec/invoke +0 -199
- data/libexec/lock +0 -199
- data/libexec/migrate +0 -199
- data/libexec/plan +0 -199
- data/libexec/release +0 -199
- data/libexec/repl +0 -199
- data/libexec/restart +0 -199
- data/libexec/rollback +0 -199
- data/libexec/shell +0 -199
- data/libexec/stage +0 -199
- data/libexec/task +0 -199
- data/libexec/unlock +0 -199
data/libexec/migrate
DELETED
@@ -1,199 +0,0 @@
|
|
1
|
-
#!/bin/bash -e
|
2
|
-
|
3
|
-
export LOCAL_ONLY=
|
4
|
-
|
5
|
-
case "$(basename $0)" in
|
6
|
-
invoke)
|
7
|
-
export COMMAND="$1"; shift
|
8
|
-
|
9
|
-
if [[ -n $1 ]]; then
|
10
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
11
|
-
fi
|
12
|
-
|
13
|
-
tmp_invoke=$(mktemp -t XXXXXXXXX)
|
14
|
-
bundle exec cap "$@" invoke 2>&1 | perl -pe 's{.\[\d+m}{}g' | perl -ne 'm{^\s*\*+\s*\[(out|err)\s*::\s*([^]]+)\] ?(.*)} && print "$1 $2 $3\n"' > $tmp_invoke 2>&1
|
15
|
-
|
16
|
-
cat $tmp_invoke | awk '{print $2}' | sort -u | while read -r nm_host; do
|
17
|
-
egrep "^(out|err) $nm_host" $tmp_invoke || true
|
18
|
-
echo
|
19
|
-
done
|
20
|
-
rm -f $tmp_invoke
|
21
|
-
;;
|
22
|
-
*)
|
23
|
-
if [[ -n $1 ]]; then
|
24
|
-
set -- $(for a in "$@"; do echo $a; done)
|
25
|
-
fi
|
26
|
-
|
27
|
-
case "$(basename $0)" in
|
28
|
-
debug)
|
29
|
-
LOCAL_ONLY=true
|
30
|
-
if [[ -z $1 ]]; then
|
31
|
-
set "world"
|
32
|
-
fi
|
33
|
-
|
34
|
-
if [[ -n $1 ]]; then
|
35
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
36
|
-
fi
|
37
|
-
;;
|
38
|
-
|
39
|
-
hosts)
|
40
|
-
LOCAL_ONLY=true
|
41
|
-
{
|
42
|
-
if [[ -n $1 ]]; then
|
43
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
44
|
-
fi
|
45
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | awk '{print $NF}' | sort -u
|
46
|
-
;;
|
47
|
-
|
48
|
-
dna)
|
49
|
-
LOCAL_ONLY=true
|
50
|
-
{
|
51
|
-
echo "eea914aaa8dde6fdae29242b1084a2b0415eefaf ---"
|
52
|
-
if [[ -n $1 ]]; then
|
53
|
-
cap $(for a in "$@"; do echo $a.yaml; done)
|
54
|
-
fi
|
55
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | sed 's#eea914aaa8dde6fdae29242b1084a2b0415eefaf ##'
|
56
|
-
;;
|
57
|
-
|
58
|
-
task)
|
59
|
-
if [[ -n $1 ]]; then
|
60
|
-
nm_task=$1; shift
|
61
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
62
|
-
fi
|
63
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate "$nm_task"
|
64
|
-
;;
|
65
|
-
|
66
|
-
*)
|
67
|
-
if [[ -n $1 ]]; then
|
68
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
69
|
-
fi
|
70
|
-
case "$(basename $0)" in
|
71
|
-
deploy)
|
72
|
-
bundle exec cap "$@" deploy:lock deploy
|
73
|
-
;;
|
74
|
-
|
75
|
-
release)
|
76
|
-
bundle exec cap "$@" deploy:lock deploy
|
77
|
-
;;
|
78
|
-
|
79
|
-
stage)
|
80
|
-
bundle exec cap "$@" deploy:lock deploy:update_code deploy:symlink_next
|
81
|
-
;;
|
82
|
-
|
83
|
-
restart)
|
84
|
-
bundle exec cap "$@" deploy:lock deploy:restart
|
85
|
-
;;
|
86
|
-
|
87
|
-
config)
|
88
|
-
bundle exec cap "$@" deploy:lock deploy:config
|
89
|
-
;;
|
90
|
-
|
91
|
-
build)
|
92
|
-
bundle exec cap "$@" deploy:lock deploy:build
|
93
|
-
;;
|
94
|
-
|
95
|
-
dist)
|
96
|
-
bundle exec cap "$@" deploy:lock deploy:dist
|
97
|
-
;;
|
98
|
-
|
99
|
-
activate)
|
100
|
-
bundle exec cap "$@" deploy:lock deploy:symlink deploy:restart
|
101
|
-
;;
|
102
|
-
|
103
|
-
rollback)
|
104
|
-
bundle exec cap "$@" deploy:lock deploy:rollback
|
105
|
-
;;
|
106
|
-
|
107
|
-
check)
|
108
|
-
bundle exec cap "$@" deploy:lock deploy:check
|
109
|
-
;;
|
110
|
-
|
111
|
-
plan)
|
112
|
-
bundle exec cap "$@" deploy:lock deploy:plan
|
113
|
-
;;
|
114
|
-
|
115
|
-
lock)
|
116
|
-
case "${1%.app}" in
|
117
|
-
compare|migrate)
|
118
|
-
nm_lock="${1%.app}"; shift
|
119
|
-
bundle exec cap "$@" deploy:dont_unlock "deploy:lock_${nm_lock}"
|
120
|
-
;;
|
121
|
-
*)
|
122
|
-
bundle exec cap "$@" deploy:dont_unlock deploy:lock
|
123
|
-
;;
|
124
|
-
esac
|
125
|
-
;;
|
126
|
-
|
127
|
-
unlock)
|
128
|
-
case "${1%.app}" in
|
129
|
-
compare|migrate)
|
130
|
-
nm_lock="${1%.app}"; shift
|
131
|
-
bundle exec cap "$@" "deploy:unlock_${nm_lock}"
|
132
|
-
;;
|
133
|
-
*)
|
134
|
-
bundle exec cap "$@" deploy:unlock
|
135
|
-
;;
|
136
|
-
esac
|
137
|
-
;;
|
138
|
-
|
139
|
-
shell)
|
140
|
-
bundle exec cap "$@" shell
|
141
|
-
;;
|
142
|
-
|
143
|
-
compare)
|
144
|
-
bundle exec cap "$@" deploy:lock_compare deploy:compare
|
145
|
-
;;
|
146
|
-
|
147
|
-
repl)
|
148
|
-
bundle exec cap "$@" deploy:lock_compare deploy:repl
|
149
|
-
;;
|
150
|
-
|
151
|
-
migrate)
|
152
|
-
want_list=
|
153
|
-
if [[ "${1%.app}" = "list" ]]; then
|
154
|
-
want_list=1; shift
|
155
|
-
fi
|
156
|
-
|
157
|
-
change_group=
|
158
|
-
migration=
|
159
|
-
case "${1%.app}" in
|
160
|
-
data)
|
161
|
-
change_group=${1%.app}; shift
|
162
|
-
;;
|
163
|
-
pre)
|
164
|
-
change_group=${1%.app}; shift
|
165
|
-
;;
|
166
|
-
during)
|
167
|
-
change_group=${1%.app} shift
|
168
|
-
;;
|
169
|
-
post)
|
170
|
-
change_group=${1%.app}; shift
|
171
|
-
;;
|
172
|
-
[0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789])
|
173
|
-
migration=${1%.app}; shift
|
174
|
-
;;
|
175
|
-
esac
|
176
|
-
|
177
|
-
if [[ -n $change_group ]]; then
|
178
|
-
if [[ -n $want_list ]]; then
|
179
|
-
echo "listing change group $change_group"
|
180
|
-
else
|
181
|
-
echo "running change group $change_group"
|
182
|
-
fi
|
183
|
-
elif [[ -n $migration ]]; then
|
184
|
-
echo "running migration $migratio"
|
185
|
-
elif [[ -n $want_list ]]; then
|
186
|
-
echo "listing migrations"
|
187
|
-
fi
|
188
|
-
|
189
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate
|
190
|
-
;;
|
191
|
-
|
192
|
-
*)
|
193
|
-
bundle exec cap "$@"
|
194
|
-
;;
|
195
|
-
esac
|
196
|
-
esac
|
197
|
-
;;
|
198
|
-
esac
|
199
|
-
|
data/libexec/plan
DELETED
@@ -1,199 +0,0 @@
|
|
1
|
-
#!/bin/bash -e
|
2
|
-
|
3
|
-
export LOCAL_ONLY=
|
4
|
-
|
5
|
-
case "$(basename $0)" in
|
6
|
-
invoke)
|
7
|
-
export COMMAND="$1"; shift
|
8
|
-
|
9
|
-
if [[ -n $1 ]]; then
|
10
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
11
|
-
fi
|
12
|
-
|
13
|
-
tmp_invoke=$(mktemp -t XXXXXXXXX)
|
14
|
-
bundle exec cap "$@" invoke 2>&1 | perl -pe 's{.\[\d+m}{}g' | perl -ne 'm{^\s*\*+\s*\[(out|err)\s*::\s*([^]]+)\] ?(.*)} && print "$1 $2 $3\n"' > $tmp_invoke 2>&1
|
15
|
-
|
16
|
-
cat $tmp_invoke | awk '{print $2}' | sort -u | while read -r nm_host; do
|
17
|
-
egrep "^(out|err) $nm_host" $tmp_invoke || true
|
18
|
-
echo
|
19
|
-
done
|
20
|
-
rm -f $tmp_invoke
|
21
|
-
;;
|
22
|
-
*)
|
23
|
-
if [[ -n $1 ]]; then
|
24
|
-
set -- $(for a in "$@"; do echo $a; done)
|
25
|
-
fi
|
26
|
-
|
27
|
-
case "$(basename $0)" in
|
28
|
-
debug)
|
29
|
-
LOCAL_ONLY=true
|
30
|
-
if [[ -z $1 ]]; then
|
31
|
-
set "world"
|
32
|
-
fi
|
33
|
-
|
34
|
-
if [[ -n $1 ]]; then
|
35
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
36
|
-
fi
|
37
|
-
;;
|
38
|
-
|
39
|
-
hosts)
|
40
|
-
LOCAL_ONLY=true
|
41
|
-
{
|
42
|
-
if [[ -n $1 ]]; then
|
43
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
44
|
-
fi
|
45
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | awk '{print $NF}' | sort -u
|
46
|
-
;;
|
47
|
-
|
48
|
-
dna)
|
49
|
-
LOCAL_ONLY=true
|
50
|
-
{
|
51
|
-
echo "eea914aaa8dde6fdae29242b1084a2b0415eefaf ---"
|
52
|
-
if [[ -n $1 ]]; then
|
53
|
-
cap $(for a in "$@"; do echo $a.yaml; done)
|
54
|
-
fi
|
55
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | sed 's#eea914aaa8dde6fdae29242b1084a2b0415eefaf ##'
|
56
|
-
;;
|
57
|
-
|
58
|
-
task)
|
59
|
-
if [[ -n $1 ]]; then
|
60
|
-
nm_task=$1; shift
|
61
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
62
|
-
fi
|
63
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate "$nm_task"
|
64
|
-
;;
|
65
|
-
|
66
|
-
*)
|
67
|
-
if [[ -n $1 ]]; then
|
68
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
69
|
-
fi
|
70
|
-
case "$(basename $0)" in
|
71
|
-
deploy)
|
72
|
-
bundle exec cap "$@" deploy:lock deploy
|
73
|
-
;;
|
74
|
-
|
75
|
-
release)
|
76
|
-
bundle exec cap "$@" deploy:lock deploy
|
77
|
-
;;
|
78
|
-
|
79
|
-
stage)
|
80
|
-
bundle exec cap "$@" deploy:lock deploy:update_code deploy:symlink_next
|
81
|
-
;;
|
82
|
-
|
83
|
-
restart)
|
84
|
-
bundle exec cap "$@" deploy:lock deploy:restart
|
85
|
-
;;
|
86
|
-
|
87
|
-
config)
|
88
|
-
bundle exec cap "$@" deploy:lock deploy:config
|
89
|
-
;;
|
90
|
-
|
91
|
-
build)
|
92
|
-
bundle exec cap "$@" deploy:lock deploy:build
|
93
|
-
;;
|
94
|
-
|
95
|
-
dist)
|
96
|
-
bundle exec cap "$@" deploy:lock deploy:dist
|
97
|
-
;;
|
98
|
-
|
99
|
-
activate)
|
100
|
-
bundle exec cap "$@" deploy:lock deploy:symlink deploy:restart
|
101
|
-
;;
|
102
|
-
|
103
|
-
rollback)
|
104
|
-
bundle exec cap "$@" deploy:lock deploy:rollback
|
105
|
-
;;
|
106
|
-
|
107
|
-
check)
|
108
|
-
bundle exec cap "$@" deploy:lock deploy:check
|
109
|
-
;;
|
110
|
-
|
111
|
-
plan)
|
112
|
-
bundle exec cap "$@" deploy:lock deploy:plan
|
113
|
-
;;
|
114
|
-
|
115
|
-
lock)
|
116
|
-
case "${1%.app}" in
|
117
|
-
compare|migrate)
|
118
|
-
nm_lock="${1%.app}"; shift
|
119
|
-
bundle exec cap "$@" deploy:dont_unlock "deploy:lock_${nm_lock}"
|
120
|
-
;;
|
121
|
-
*)
|
122
|
-
bundle exec cap "$@" deploy:dont_unlock deploy:lock
|
123
|
-
;;
|
124
|
-
esac
|
125
|
-
;;
|
126
|
-
|
127
|
-
unlock)
|
128
|
-
case "${1%.app}" in
|
129
|
-
compare|migrate)
|
130
|
-
nm_lock="${1%.app}"; shift
|
131
|
-
bundle exec cap "$@" "deploy:unlock_${nm_lock}"
|
132
|
-
;;
|
133
|
-
*)
|
134
|
-
bundle exec cap "$@" deploy:unlock
|
135
|
-
;;
|
136
|
-
esac
|
137
|
-
;;
|
138
|
-
|
139
|
-
shell)
|
140
|
-
bundle exec cap "$@" shell
|
141
|
-
;;
|
142
|
-
|
143
|
-
compare)
|
144
|
-
bundle exec cap "$@" deploy:lock_compare deploy:compare
|
145
|
-
;;
|
146
|
-
|
147
|
-
repl)
|
148
|
-
bundle exec cap "$@" deploy:lock_compare deploy:repl
|
149
|
-
;;
|
150
|
-
|
151
|
-
migrate)
|
152
|
-
want_list=
|
153
|
-
if [[ "${1%.app}" = "list" ]]; then
|
154
|
-
want_list=1; shift
|
155
|
-
fi
|
156
|
-
|
157
|
-
change_group=
|
158
|
-
migration=
|
159
|
-
case "${1%.app}" in
|
160
|
-
data)
|
161
|
-
change_group=${1%.app}; shift
|
162
|
-
;;
|
163
|
-
pre)
|
164
|
-
change_group=${1%.app}; shift
|
165
|
-
;;
|
166
|
-
during)
|
167
|
-
change_group=${1%.app} shift
|
168
|
-
;;
|
169
|
-
post)
|
170
|
-
change_group=${1%.app}; shift
|
171
|
-
;;
|
172
|
-
[0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789])
|
173
|
-
migration=${1%.app}; shift
|
174
|
-
;;
|
175
|
-
esac
|
176
|
-
|
177
|
-
if [[ -n $change_group ]]; then
|
178
|
-
if [[ -n $want_list ]]; then
|
179
|
-
echo "listing change group $change_group"
|
180
|
-
else
|
181
|
-
echo "running change group $change_group"
|
182
|
-
fi
|
183
|
-
elif [[ -n $migration ]]; then
|
184
|
-
echo "running migration $migratio"
|
185
|
-
elif [[ -n $want_list ]]; then
|
186
|
-
echo "listing migrations"
|
187
|
-
fi
|
188
|
-
|
189
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate
|
190
|
-
;;
|
191
|
-
|
192
|
-
*)
|
193
|
-
bundle exec cap "$@"
|
194
|
-
;;
|
195
|
-
esac
|
196
|
-
esac
|
197
|
-
;;
|
198
|
-
esac
|
199
|
-
|
data/libexec/release
DELETED
@@ -1,199 +0,0 @@
|
|
1
|
-
#!/bin/bash -e
|
2
|
-
|
3
|
-
export LOCAL_ONLY=
|
4
|
-
|
5
|
-
case "$(basename $0)" in
|
6
|
-
invoke)
|
7
|
-
export COMMAND="$1"; shift
|
8
|
-
|
9
|
-
if [[ -n $1 ]]; then
|
10
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
11
|
-
fi
|
12
|
-
|
13
|
-
tmp_invoke=$(mktemp -t XXXXXXXXX)
|
14
|
-
bundle exec cap "$@" invoke 2>&1 | perl -pe 's{.\[\d+m}{}g' | perl -ne 'm{^\s*\*+\s*\[(out|err)\s*::\s*([^]]+)\] ?(.*)} && print "$1 $2 $3\n"' > $tmp_invoke 2>&1
|
15
|
-
|
16
|
-
cat $tmp_invoke | awk '{print $2}' | sort -u | while read -r nm_host; do
|
17
|
-
egrep "^(out|err) $nm_host" $tmp_invoke || true
|
18
|
-
echo
|
19
|
-
done
|
20
|
-
rm -f $tmp_invoke
|
21
|
-
;;
|
22
|
-
*)
|
23
|
-
if [[ -n $1 ]]; then
|
24
|
-
set -- $(for a in "$@"; do echo $a; done)
|
25
|
-
fi
|
26
|
-
|
27
|
-
case "$(basename $0)" in
|
28
|
-
debug)
|
29
|
-
LOCAL_ONLY=true
|
30
|
-
if [[ -z $1 ]]; then
|
31
|
-
set "world"
|
32
|
-
fi
|
33
|
-
|
34
|
-
if [[ -n $1 ]]; then
|
35
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
36
|
-
fi
|
37
|
-
;;
|
38
|
-
|
39
|
-
hosts)
|
40
|
-
LOCAL_ONLY=true
|
41
|
-
{
|
42
|
-
if [[ -n $1 ]]; then
|
43
|
-
cap $(for a in "$@"; do echo $a.echo; done)
|
44
|
-
fi
|
45
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | awk '{print $NF}' | sort -u
|
46
|
-
;;
|
47
|
-
|
48
|
-
dna)
|
49
|
-
LOCAL_ONLY=true
|
50
|
-
{
|
51
|
-
echo "eea914aaa8dde6fdae29242b1084a2b0415eefaf ---"
|
52
|
-
if [[ -n $1 ]]; then
|
53
|
-
cap $(for a in "$@"; do echo $a.yaml; done)
|
54
|
-
fi
|
55
|
-
} 2>&1 | grep eea914aaa8dde6fdae29242b1084a2b0415eefaf | sed 's#eea914aaa8dde6fdae29242b1084a2b0415eefaf ##'
|
56
|
-
;;
|
57
|
-
|
58
|
-
task)
|
59
|
-
if [[ -n $1 ]]; then
|
60
|
-
nm_task=$1; shift
|
61
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
62
|
-
fi
|
63
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate "$nm_task"
|
64
|
-
;;
|
65
|
-
|
66
|
-
*)
|
67
|
-
if [[ -n $1 ]]; then
|
68
|
-
set -- $(for a in "$@"; do echo $a.app; done)
|
69
|
-
fi
|
70
|
-
case "$(basename $0)" in
|
71
|
-
deploy)
|
72
|
-
bundle exec cap "$@" deploy:lock deploy
|
73
|
-
;;
|
74
|
-
|
75
|
-
release)
|
76
|
-
bundle exec cap "$@" deploy:lock deploy
|
77
|
-
;;
|
78
|
-
|
79
|
-
stage)
|
80
|
-
bundle exec cap "$@" deploy:lock deploy:update_code deploy:symlink_next
|
81
|
-
;;
|
82
|
-
|
83
|
-
restart)
|
84
|
-
bundle exec cap "$@" deploy:lock deploy:restart
|
85
|
-
;;
|
86
|
-
|
87
|
-
config)
|
88
|
-
bundle exec cap "$@" deploy:lock deploy:config
|
89
|
-
;;
|
90
|
-
|
91
|
-
build)
|
92
|
-
bundle exec cap "$@" deploy:lock deploy:build
|
93
|
-
;;
|
94
|
-
|
95
|
-
dist)
|
96
|
-
bundle exec cap "$@" deploy:lock deploy:dist
|
97
|
-
;;
|
98
|
-
|
99
|
-
activate)
|
100
|
-
bundle exec cap "$@" deploy:lock deploy:symlink deploy:restart
|
101
|
-
;;
|
102
|
-
|
103
|
-
rollback)
|
104
|
-
bundle exec cap "$@" deploy:lock deploy:rollback
|
105
|
-
;;
|
106
|
-
|
107
|
-
check)
|
108
|
-
bundle exec cap "$@" deploy:lock deploy:check
|
109
|
-
;;
|
110
|
-
|
111
|
-
plan)
|
112
|
-
bundle exec cap "$@" deploy:lock deploy:plan
|
113
|
-
;;
|
114
|
-
|
115
|
-
lock)
|
116
|
-
case "${1%.app}" in
|
117
|
-
compare|migrate)
|
118
|
-
nm_lock="${1%.app}"; shift
|
119
|
-
bundle exec cap "$@" deploy:dont_unlock "deploy:lock_${nm_lock}"
|
120
|
-
;;
|
121
|
-
*)
|
122
|
-
bundle exec cap "$@" deploy:dont_unlock deploy:lock
|
123
|
-
;;
|
124
|
-
esac
|
125
|
-
;;
|
126
|
-
|
127
|
-
unlock)
|
128
|
-
case "${1%.app}" in
|
129
|
-
compare|migrate)
|
130
|
-
nm_lock="${1%.app}"; shift
|
131
|
-
bundle exec cap "$@" "deploy:unlock_${nm_lock}"
|
132
|
-
;;
|
133
|
-
*)
|
134
|
-
bundle exec cap "$@" deploy:unlock
|
135
|
-
;;
|
136
|
-
esac
|
137
|
-
;;
|
138
|
-
|
139
|
-
shell)
|
140
|
-
bundle exec cap "$@" shell
|
141
|
-
;;
|
142
|
-
|
143
|
-
compare)
|
144
|
-
bundle exec cap "$@" deploy:lock_compare deploy:compare
|
145
|
-
;;
|
146
|
-
|
147
|
-
repl)
|
148
|
-
bundle exec cap "$@" deploy:lock_compare deploy:repl
|
149
|
-
;;
|
150
|
-
|
151
|
-
migrate)
|
152
|
-
want_list=
|
153
|
-
if [[ "${1%.app}" = "list" ]]; then
|
154
|
-
want_list=1; shift
|
155
|
-
fi
|
156
|
-
|
157
|
-
change_group=
|
158
|
-
migration=
|
159
|
-
case "${1%.app}" in
|
160
|
-
data)
|
161
|
-
change_group=${1%.app}; shift
|
162
|
-
;;
|
163
|
-
pre)
|
164
|
-
change_group=${1%.app}; shift
|
165
|
-
;;
|
166
|
-
during)
|
167
|
-
change_group=${1%.app} shift
|
168
|
-
;;
|
169
|
-
post)
|
170
|
-
change_group=${1%.app}; shift
|
171
|
-
;;
|
172
|
-
[0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789][0123456789])
|
173
|
-
migration=${1%.app}; shift
|
174
|
-
;;
|
175
|
-
esac
|
176
|
-
|
177
|
-
if [[ -n $change_group ]]; then
|
178
|
-
if [[ -n $want_list ]]; then
|
179
|
-
echo "listing change group $change_group"
|
180
|
-
else
|
181
|
-
echo "running change group $change_group"
|
182
|
-
fi
|
183
|
-
elif [[ -n $migration ]]; then
|
184
|
-
echo "running migration $migratio"
|
185
|
-
elif [[ -n $want_list ]]; then
|
186
|
-
echo "listing migrations"
|
187
|
-
fi
|
188
|
-
|
189
|
-
bundle exec cap "$@" deploy:lock_migrate deploy:migrate
|
190
|
-
;;
|
191
|
-
|
192
|
-
*)
|
193
|
-
bundle exec cap "$@"
|
194
|
-
;;
|
195
|
-
esac
|
196
|
-
esac
|
197
|
-
;;
|
198
|
-
esac
|
199
|
-
|