Skip to content

Commit fd40792

Browse files
committed
修复example打包部署错误
1 parent 3d5df25 commit fd40792

4 files changed

Lines changed: 10 additions & 8 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,4 @@ logs/
1313
*MANIFEST
1414
*artifacts
1515
.DS_Store
16+
env

raft-java-example/deploy.sh

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,31 +2,31 @@
22

33
mvn clean package
44

5-
EXAMPLE_ZIP=raft-java-example-1.8.0-deploy.zip
5+
EXAMPLE_TAR=raft-java-example-1.8.0-deploy.tar.gz
66
ROOT_DIR=./env
77
mkdir -p $ROOT_DIR
88
cd $ROOT_DIR
99

1010
mkdir example1
1111
cd example1
12-
cp -f ../../target/$EXAMPLE_ZIP .
13-
tar -zxvf $EXAMPLE_ZIP
12+
cp -f ../../target/$EXAMPLE_TAR .
13+
tar -zxvf $EXAMPLE_TAR
1414
chmod +x ./bin/*.sh
1515
nohup ./bin/run_server.sh ./data "127.0.0.1:8051:1,127.0.0.1:8052:2,127.0.0.1:8053:3" "127.0.0.1:8051:1" &
1616
cd -
1717

1818
mkdir example2
1919
cd example2
20-
cp -f ../../target/$EXAMPLE_ZIP .
21-
tar -zxvf $EXAMPLE_ZIP
20+
cp -f ../../target/$EXAMPLE_TAR .
21+
tar -zxvf $EXAMPLE_TAR
2222
chmod +x ./bin/*.sh
2323
nohup ./bin/run_server.sh ./data "127.0.0.1:8051:1,127.0.0.1:8052:2,127.0.0.1:8053:3" "127.0.0.1:8052:2" &
2424
cd -
2525

2626
mkdir example3
2727
cd example3
28-
cp -f ../../target/$EXAMPLE_ZIP .
29-
tar -zxvf $EXAMPLE_ZIP
28+
cp -f ../../target/$EXAMPLE_TAR .
29+
tar -zxvf $EXAMPLE_TAR
3030
chmod +x ./bin/*.sh
3131
nohup ./bin/run_server.sh ./data "127.0.0.1:8051:1,127.0.0.1:8052:2,127.0.0.1:8053:3" "127.0.0.1:8053:3" &
3232
cd -

raft-java-example/pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@
7878
<descriptors>
7979
<decriptor>src/main/assembly/assembly.xml</decriptor>
8080
</descriptors>
81+
<tarLongFileMode>posix</tarLongFileMode>
8182
</configuration>
8283
<executions>
8384
<execution>

raft-java-example/src/main/assembly/assembly.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
http://maven.apache.org/xsd/assembly-2.0.0.xsd">
55
<id>deploy</id>
66
<formats>
7-
<format>zip</format>
7+
<format>tar.gz</format>
88
</formats>
99
<includeBaseDirectory>false</includeBaseDirectory>
1010
<fileSets>

0 commit comments

Comments
 (0)