add services to docker
This commit is contained in:
Родитель
d41e137f01
Коммит
a61d87a613
|
@ -160,7 +160,6 @@ namespace Steeltoe.Tooling.Models
|
|||
var service = new Service()
|
||||
{
|
||||
Name = svcspec.Type,
|
||||
Type = svcspec.Type,
|
||||
Image = svcspec.Image,
|
||||
Port = svcspec.Port
|
||||
};
|
||||
|
|
|
@ -34,21 +34,15 @@ namespace Steeltoe.Tooling.Models
|
|||
private string _name;
|
||||
|
||||
/// <summary>
|
||||
/// Service type.
|
||||
/// Docker image.
|
||||
/// </summary>
|
||||
[YamlMember(Alias = "type")]
|
||||
public string Type { get; set; }
|
||||
[YamlMember(Alias = "image")]
|
||||
public string Image { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Service port.
|
||||
/// </summary>
|
||||
[YamlMember(Alias = "port")]
|
||||
public int Port { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Docker image.
|
||||
/// </summary>
|
||||
[YamlMember(Alias = "image")]
|
||||
public string Image { get; set; }
|
||||
}
|
||||
}
|
||||
|
|
|
@ -24,4 +24,5 @@
|
|||
image: steeltoeoss/redis-amd64-linux:4.0.11
|
||||
port: 5672
|
||||
nugets:
|
||||
- Microsoft.Extensions.Caching.Redis
|
||||
- Microsoft.Extensions.Caching.StackExchangeRedis
|
||||
|
|
|
@ -6,3 +6,7 @@ services:
|
|||
<project.Protocols: {protocol |- "<protocol.Port>:<protocol.Port>"}; separator="\n">
|
||||
volumes:
|
||||
- .:/<project.Name>
|
||||
<project.Services: {svc |<svc.Name>:
|
||||
image: <svc.Image>
|
||||
ports:
|
||||
- <svc.Port>}; separator="\n">
|
||||
|
|
Загрузка…
Ссылка в новой задаче