Tag: 苹果系统

去从docker容器无法访问imageproxy

我正在尝试在Mac OSX上通过Docker Cloud部署优秀的Go image代理服务器https://github.com/willnorris/imageproxy作为docker容器。 我无法让我的浏览器访问容器 docker run -i -t -p 8080:8080 willnorris/imageproxy:latest /go/bin/imageproxy -addr 0.0.0.0:8080 应该在docker-machine ip [vmname]暴露服务器,在这种情况下是192.168.56.100 我以相同的方式运行vanilla Express服务器来validation我的设置。 有人会知道这个服务的dockerization是什么? https://hub.docker.com/r/willnorris/imageproxy/

Go – 使用xgo库与CGO交叉编译

我试图编译一个GO应用程序,它使用gokiri库。 我安装了docker并在本地编译了xgo交叉编译器。 当试图执行以下命令时: ./xgo mydomain.com/test/test-app 我得到以下错误: In file included from /usr/include/libxml2/libxml/parser.h:810:0, from /usr/include/libxml2/libxml/globals.h:18, from /usr/include/libxml2/libxml/threads.h:35, from /usr/include/libxml2/libxml/xmlmemory.h:218, from /usr/include/libxml2/libxml/tree.h:1307, from ../../github.com/moovweb/gokogiri/help/help.go:6: /usr/include/libxml2/libxml/encoding.h:28:19: fatal error: iconv.h: No such file or directory 我已经安装了xcode-tools帮助我编译我的机器(mac ox El Capitan)。 但是,我不能把它编译到其他环境。 任何帮助将不胜感激。 谢谢。 更新1: 我试图添加依赖关系,但得到了相同的结果: ./xgo –deps /usr/local/Cellar/libiconv/1.14/ mydomain.com/test/test-app 甚至在xgo的日志中提到这个库已经被caching了: Dependency already cached: /Users/macuser/.xgo-cache/1.14.

IntelliJ IDEA for Mac中的Docker无法正常工作

我正在遵循本指南: https ://www.jetbrains.com/help/idea/2016.3/docker.html#d213398e640但我不能让它与我的docker-compose.yml一起工作。 按照指导和configuration我的项目没有问题。 但是,当我尝试启动泊坞窗运行configuration时,它不启动。 我所得到的是IDEA中Docker工具窗口中的鲸鱼图标上的红框。 hover它给我io.netty.channelConnectTimeoutException: Connection timed out 192.168.99.100:2376 我正在运行最新的Docker for Mac,我没有在命令行中运行的问题: docker-compose up 。 有任何想法吗?

Docker容器请求OSX上的chrome失败

我有几个使用Docker for Mac在Docker上运行的Docker容器,我已经在docker-compose文件中设置了端口映射,以便在localhost上访问它们。 这通常有效,但有时从Chrome浏览器访问它们时,请求会失败。 在这个事件中,我在docker-compose输出中看不到任何东西,暗示容器已经收到一个请求,并且这个标签只要挂了很长时间就离开它。 唯一有用的是等待片刻,然后在另一个Chrome选项卡中打开另一个url(甚至是相同的本地主机url),这有时会导致请求到本地主机通过。 我对其他浏览器(Firefox,Safari)没有任何问题,使用Ubuntu上的Chrome可以可靠地访问相同的容器。 版本: OSX:10.12.4 Docker:17.03.1-ce-mac12 Chrome:58.0.3029.110

Golang二进制内buildDocker容器,还是Mach-O可执行格式?

我真的可以在这里使用一些帮助。 我想要做的是使用标准的golang:1.5 Docker镜像来构build一个Go二进制文件,然后将这个二进制文件从容器中复制到一个基于busybox的新的最小的Docker容器中。 使用Docker安装的卷将二进制文件从容器中取出。 到目前为止,我遇到了两个问题。 主机上生成的二进制文件(并随后复制到第二个容器中)在运行file命令时似乎仍然是一个Mach-O 64位可执行file 。 Docker容器是否从主机获取GOOS和GOARCH? 当用bash手动运行容器并构buildGo二进制文件时,它现在说它是一个ELF可执行文件,但它是dynamic链接的。 我想默认情况下build立静态链接的二进制文件? 这个假设我可能是错的。 预先感谢您提供的任何帮助。 编辑:这是我使用的命令。 希望这个更清楚一点 ## golang:1.5 base image with WORKDIR set to $GOPATH/src/myproject the source ## for the project was added in when creating the 'mybuild_img' docker image ## GOPATH is set automatically in the golang image. docker run -i -v `pwd`/jenkins/out:$GOPATH/src/myproject/jenkins/out mybuild_img:latest bash […]

使用Intellij IDEA重新加载远程弹簧启动应用程序的例外

我试图使用spring devtools ,docker和IntelliJ来设置远程的spring-boot环境。 一切从这篇文章开始。 不幸的是,它随机失败,例外。 在configuration下面: Dockerfile FROM java:8 EXPOSE 8888 WORKDIR /app ADD build.gradle /app/build.gradle ADD gradlew /app/gradlew ADD gradle /app/gradle ADD src /app/src RUN ["chmod", "+x", "/app/gradlew"] 泊坞窗,compose.yml backend: build: . env_file: environment ports: – "8888:8888" volumes: – ./.gradle-docker:/root/.gradle command: "/app/gradlew clean bootRun" links: – db db: image: postgres:9.5.3 env_file: environment ports: – […]