Skip to content

Commit

Permalink
Merge pull request #44 from CloudOS-Group3/feature/trigger
Browse files Browse the repository at this point in the history
fix: Job structure and Trigger Message
  • Loading branch information
illyaks authored May 27, 2024
2 parents 349afb8 + 5b3207c commit 9ecb1d8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions pkg/api/job.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ type Job struct {
Instance Pod `json:"instance,omitempty" yaml:"instance,omitempty"`
Result string `json:"result,omitempty" yaml:"result,omitempty"`
CreateTime string `json:"createTime,omitempty" yaml:"createTime,omitempty"`
Params string `json:"params,omitempty" yaml:"params,omitempty"`
}
5 changes: 5 additions & 0 deletions pkg/api/msg_type/message.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,3 +65,8 @@ type DNSMsg struct {
NewDNS api.DNS `json:"new_dns,omitempty"`
OldDNS api.DNS `json:"old_dns,omitempty"`
}

type TriggerMsg struct {
Function api.Function `json:"function,omitempty"`
Params string `json:"params,omitempty"`
}
1 change: 1 addition & 0 deletions pkg/config/urlconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ const (
FunctionsAllURL = "/api/v1/functions"
FunctionsURL = "/api/v1/namespaces/:namespace/functions"
FunctionURL = "/api/v1/namespaces/:namespace/functions/:name"
FunctionRunURL = "/api/v1/namespaces/:namespace/functions/:name/run"

TriggersURL = "/api/v1/triggers"
TriggerURL = "/api/v1/namespace/:namespace/trigger/:name"
Expand Down

0 comments on commit 9ecb1d8

Please sign in to comment.