提交 5da3c9e6 authored 作者: chenshiying's avatar chenshiying

[新增] 部署脚本更新

上级 7b0c32e2
......@@ -35,4 +35,4 @@ build/
### project Code ###
**/src/main/resources/bin/serverTest/**
**/src/main/resources/bin/server/**
......@@ -83,6 +83,10 @@ pssh -h /home/soft/deploy/server/host_ip_skywalking.txt -i bash /usr/local/src/m
8、部署文件更新
文件进行 dos/unix 格式转换
```shell
sh formatFile.sh
```
发送最新部署文件
......@@ -90,6 +94,7 @@ pssh -h /home/soft/deploy/server/host_ip_skywalking.txt -i bash /usr/local/src/m
sh push_script.sh
```
执行初始化 /home/soft 脚本
```shell
pssh -h /home/soft/deploy/server/host_ip_push_script.txt -i bash /home/soft/initEnv.sh
......@@ -100,3 +105,6 @@ pssh -h /home/soft/deploy/server/host_ip_push_script.txt -i bash /home/soft/init
```shell
pssh -h /home/soft/deploy/server/host_ip_push_script.txt -i bash /home/soft/copyNginxConfig.sh
```
......@@ -26,7 +26,7 @@ public class GeneratorScript {
protected static String root_path = "F:\\9Git140\\loit-build-common\\loit-build-component\\loit-build-deploy-env\\src\\main\\resources\\bin";
protected static String root_path_full = root_path + "\\serverTest";
protected static String root_path_full = root_path + "\\server";
public static void main(String[] args) {
......@@ -84,9 +84,9 @@ public class GeneratorScript {
File file = new File(filePath);
if (!file.exists()) {
FileUtils.write(filePath, "#!/bin/bash ");
//TODO
FileUtils.appendNewLine(filePath, "rm -rf /home/soft/*");
//
// //TODO
// FileUtils.appendNewLine(filePath, "rm -rf /home/soft/*");
}
String deployPath = grayVersionDataDTO.getDeployPath();
......
find /home/soft -name "*.sh" | xargs sed -i 's/\r$//g'
find /home/soft -name "*.conf" | xargs sed -i 's/\r$//g'
find /home/soft -name "*.properties" | xargs sed -i 's/\r$//g'
#!/bin/bash
\cp -rf /home/soft/nginxConfig/ /usr/local/nginx/conf/conf.d.start/
\cp -rf /home/soft/nginxConfig/* /usr/local/nginx/conf/conf.d.start/
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论