azure 测试
This commit is contained in:
parent
6fd84ecba9
commit
84123c9c22
@ -30,7 +30,7 @@ namespace asg_form.Controllers
|
|||||||
{
|
{
|
||||||
logger.Warn(rootobject.EventType);
|
logger.Warn(rootobject.EventType);
|
||||||
Random random = new Random();
|
Random random = new Random();
|
||||||
string[] strings = { "upload", "--copyright 1", "--dolby 0", "--hires 0", $"--title {rootobject.EventData.Title}-直播回放{random.Next(1,99)}", "--tag 第五人格,第五人格ASG赛事", @$"{AppDomain.CurrentDomain.BaseDirectory}video\{rootobject.EventData.RelativePath}" };
|
string[] strings = { "upload", "--copyright 1", "--dolby 0", "--hires 0", $"--title {rootobject.EventData.Title}-直播回放{random.Next(1, 99)}", "--tag 第五人格,第五人格ASG赛事", @$"{AppDomain.CurrentDomain.BaseDirectory}video\{rootobject.EventData.RelativePath}" };
|
||||||
StartProcess("biliup.exe", strings);
|
StartProcess("biliup.exe", strings);
|
||||||
|
|
||||||
|
|
||||||
@ -42,24 +42,39 @@ namespace asg_form.Controllers
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public class azurereq
|
||||||
|
{
|
||||||
|
|
||||||
|
public Message message { get; set; }
|
||||||
|
|
||||||
|
public DateTime createdDate { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public class Message
|
||||||
|
{
|
||||||
|
public string text { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[Route("api/v1/Codepush/")]
|
[Route("api/v1/Codepush/")]
|
||||||
[HttpPost]
|
[HttpPost]
|
||||||
public async Task<object> Codepush([FromBody]dynamic date1)
|
public async Task<object> Codepush([FromBody] azurereq date)
|
||||||
{
|
{
|
||||||
|
|
||||||
try {
|
try
|
||||||
dynamic date = JsonConvert.DeserializeObject(Convert.ToString(date1));
|
{
|
||||||
var message = new MessageBuilder().Text($"后端推送了新的代码库\r\n详细信息:{date.message.text}").Build();
|
var message = new MessageBuilder().Text($"后端推送了新的代码库\r\n详细信息:{date.message.text}").Build();
|
||||||
|
|
||||||
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
return "ok";
|
return "ok";
|
||||||
}
|
}
|
||||||
@ -67,13 +82,12 @@ namespace asg_form.Controllers
|
|||||||
|
|
||||||
[Route("api/v1/issueadd/")]
|
[Route("api/v1/issueadd/")]
|
||||||
[HttpPost]
|
[HttpPost]
|
||||||
public async Task<object> issueadd([FromBody] dynamic date1)
|
public async Task<object> issueadd([FromBody] azurereq date)
|
||||||
{
|
{
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
dynamic date = JsonConvert.DeserializeObject(Convert.ToString(date1));
|
|
||||||
|
|
||||||
var message = new MessageBuilder().Text($"后端有新bug被提交请及时解决!\r\n详细信息:{date.message.text}").Build();
|
var message = new MessageBuilder().Text($"后端有新bug被提交请及时解决!\r\n详细信息:{date.message.text}").Build();
|
||||||
|
|
||||||
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
||||||
@ -82,7 +96,7 @@ namespace asg_form.Controllers
|
|||||||
}
|
}
|
||||||
catch
|
catch
|
||||||
{
|
{
|
||||||
var message = new MessageBuilder().Text($"后端有新bug被提交请及时解决!\r\n详细信息:{date1.ToJsonString}").Build();
|
var message = new MessageBuilder().Text($"后端有新bug被提交请及时解决!\r\n详细信息:{date}").Build();
|
||||||
|
|
||||||
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
await runbot.runbotr.SendMessageAsync(MessageEnvironment.Channel, "931217544", null, message, "931217544");
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user