Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
v1.3.4
  • Loading branch information
wzjg520 committed Sep 6, 2017
2 parents 2ebd69f + 42ba322 commit ffb55f6
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 8 deletions.
13 changes: 10 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# jiacrontab
提供可视化界面的定时任务管理工具。

1.允许设置每个脚本的超时时间,超时操作可选择邮件通知管理者,或强杀脚本进程。
1.允许设置每个脚本的超时时间,超时操作可选择邮件通知管理者,或强杀脚本进程。
2.允许设置脚本的最大并发数。
3.一台server管理多个client。
4.每个脚本都可在server端灵活配置,如测试脚本运行,查看日志,强杀进程,停止定时...。
Expand Down Expand Up @@ -45,10 +45,17 @@ $ go build .
$ nohup ./client &> client.log &
```

### 截图
### 版本升级

1、下载新版本压缩包,并解压。

2、替换旧版本中的server(或server.exe)、client(或client.exe)执行文件,以及static、template目录为新版


## 截图
![alt 截图](https://raw.githubusercontent.com/iwannay/static_dir/master/jiacrontab_preview_1.jpg)

![alt 截图2](https://raw.githubusercontent.com/iwannay/static_dir/master/jiacrontab_preview_2.jpg)

### 演示地址
## 演示地址
[demo](http://182.92.223.12:20000) 账号:admin 密码:123456
8 changes: 4 additions & 4 deletions client/crontab.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,20 +47,20 @@ type dependScript struct {

func newTaskEntity(t *proto.TaskArgs) *taskEntity {
var depends []*dependScript
var md5key string
var dependSubName string
var md5Sum string
id := fmt.Sprintf("%d", time.Now().Unix())

for k, v := range t.Depends {
md5key = fmt.Sprintf("%s-%s-%d", v.Command, v.Args, k)
md5Sum = fmt.Sprintf("%x", md5.Sum([]byte(fmt.Sprintf("%s-%s-%d", v.Command, v.Args, k))))
if v.Name == "" {
dependSubName = fmt.Sprintf("%d", libs.RandNum())
dependSubName = md5Sum
} else {
dependSubName = v.Name
}
depends = append(depends, &dependScript{
pid: id,
id: fmt.Sprintf("%s-%s-%x", t.Id, id, md5.Sum([]byte(md5key))),
id: fmt.Sprintf("%s-%s-%s", t.Id, id, md5Sum),
from: v.From,
dest: v.Dest,
command: v.Command,
Expand Down
2 changes: 1 addition & 1 deletion server/template/.VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.3.3
1.3.4

0 comments on commit ffb55f6

Please sign in to comment.