Skip to content

Commit 0f118ca

Browse files
committed
Add more volumes to create
1 parent 784b675 commit 0f118ca

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

bin/dev_command/volume

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11

22
usage() {
33
echo "Usage:";
4-
echo "- ${DEV_SELF} ${DEV_COMMAND} {workspace|mysql} localpath";
4+
echo "- ${DEV_SELF} ${DEV_COMMAND} {workspace|mysql|mysql8|elasticsearch6|elasticsearch7} localpath";
55
echo " create a volume pointing to the localpath";
6-
echo "- ${DEV_SELF} ${DEV_COMMAND} rm {workspace|mysql}";
6+
echo "- ${DEV_SELF} ${DEV_COMMAND} rm {workspace|mysql|mysql8|elasticsearch6|elasticsearch7}";
77
echo " remove a volume";
88
echo "- ${DEV_SELF} ${DEV_COMMAND} ls";
99
echo " list current volume mapping"
@@ -23,8 +23,14 @@ current() {
2323
create() {
2424
if [ "$1" == 'mysql' ]; then
2525
local VOLUME_TYPE='mysql';
26+
elif [ "$1" == 'mysql8' ]; then
27+
local VOLUME_TYPE='mysql8';
2628
elif [ "$1" == 'workspace' ]; then
2729
local VOLUME_TYPE='workspace';
30+
elif [ "$1" == 'elasticsearch6' ]; then
31+
local VOLUME_TYPE='elasticsearch6';
32+
elif [ "$1" == 'elasticsearch7' ]; then
33+
local VOLUME_TYPE='elasticsearch7';
2834
else
2935
usage;
3036
return $?;
@@ -53,8 +59,14 @@ create() {
5359
remove() {
5460
if [ "$1" == 'mysql' ]; then
5561
local VOLUME_TYPE='mysql';
62+
elif [ "$1" == 'mysql8' ]; then
63+
local VOLUME_TYPE='mysql8';
5664
elif [ "$1" == 'workspace' ]; then
5765
local VOLUME_TYPE='workspace';
66+
elif [ "$1" == 'elasticsearch6' ]; then
67+
local VOLUME_TYPE='elasticsearch6';
68+
elif [ "$1" == 'elasticsearch7' ]; then
69+
local VOLUME_TYPE='elasticsearch7';
5870
else
5971
usage;
6072
return $?;

0 commit comments

Comments
 (0)