我正在使用visual studio 2017上的docker工作微型服务。我已经处理了这个错误半天。
public class Hydra {
// MAIN method
public static void main(String[] args) {
Hydra hydra = new Hydra(1,1,1);
Node head2 = hydra.body.getChildren().get(0).getChildren().get(0);
System.out.println(head2.toString()); // >> Node at Level 2 has 1 child node.
//head2.cutHead(); // Doesn't work because cutHead() is a HydraNode method, not a Node method.
}
// Member Variables
public static int regrowFactor = 2; // Every time a head is cut off, the hydra clones the remaining branches. In the original video, the hydra forms two new clones.
HydraNode body;
// Constructors
public Hydra() {
body = new HydraNode(0); // the body is just a new Node at level 0
}
public Hydra(int... headsPerLevel) {
body = new HydraNode(0, headsPerLevel);
}
}
这是撰写内容 版本:' 3'
Severity Code Description Project File Line Suppression State
Error Creating network "dockercompose8357222465790585823_default" with the default driver
Building Pricing.api
invalid reference format: repository name must be lowercase.
和泊坞窗文件
services:
Pricing.api:
image: Pricing.api
build:
context: ../PricingAPI
dockerfile: Dockerfile
这是ci 版本:' 3'
FROM microsoft/aspnetcore:2.0
ARG source
WORKDIR /app
EXPOSE 80
COPY ${source:-obj/Docker/publish} .
ENTRYPOINT ["dotnet", "PricingAPI.dll"]
当它通过存储库说时它指的是什么?
答案 0 :(得分:4)
事实证明,通过存储库,它意味着“服务”。我更新了服务名称,如下所示,它可以工作。
services:
Pricing.api: => pricing.api with lowercase ‘p’
environment:
- ASPNETCORE_ENVIRONMENT=Development
ports:
- "80"
应该说
参考格式无效。服务名称必须小写。
这是一个令人困惑的错误消息。这是Docker团队必须解决的问题。