我已經建立了我的搬運工回購,下面是docker-compose.yml
文件:搬運工登錄到關係連接拒絕
version: '2'
networks:
prodnetwork:
driver: bridge
services:
nexus:
image: sonatype/nexus3
volumes:
- "nexus-data:/nexus-data"
ports:
- "8081:8081"
- "8082:8082"
- "8083:8083"
- "8084:8084"
- "8085:8085"
- "8086:8086"
- "8087:8087"
- "8088:8088"
networks:
- prodnetwork
jenkins:
image: library/jenkins
ports:
- "8080:8080"
networks:
- prodnetwork
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /usr/bin/docker:/usr/bin/docker
- /opt/jenkins/:/var/lib/jenkins/
depends_on:
- nexus
- sonar
environment:
- NEXUS_PORT=8081
- SONAR_PORT=9000
- SONAR_DB_PORT=5432
sonar:
build: ./sonar
ports:
- "9000:9000"
- "5432:5432"
networks:
- prodnetwork
depends_on:
- sonardb
environment:
- SONARQUBE_JDBC_URL=jdbc:postgresql://sonardb:5432/sonar
- SONARQUBE_JDBC_USERNAME=sonar
- SONARQUBE_JDBC_PASSWORD=sonar
sonardb:
networks:
- prodnetwork
image: postgres
environment:
- POSTGRES_USER=sonar
- POSTGRES_PASSWORD=sonar
volumes:
- /opt/postgres/data:/var/lib/postgresql/data
volumes:
nexus-data: {}
在文件docker.service
我已經加入:
DOCKER_OPTS=」$DOCKER_OPTS –insecure-registry=192.168.200.150:8083″
在關係3 I已使用http端口創建回購:8083
和https:8123
。當我試圖通過命令登錄
docker login -u admin 192.168.200.150:8083
或8123
並在關係管理正確的密碼類型上寫着:
Error response from daemon: Get https://192.168.200.150:8083/v2/: dial tcp 192.168.200.150:8083: getskopt: connection refused.
或
Error response from daemon: Get https://192.168.200.150:8083/v2/: http: server gave HTTP response to HTTPS client
你有一個想法,我該怎麼做?我堅持下去:/ 我正在使用CentOs linux
是https://192.168的地址。 200.150:8083/v2/_catalog返回結果。如果不是註冊表不起作用。 – yamenk
我有這樣的迴應: {「repositories」:[]} – xross
你可以嘗試與端口8081連接? – yamenk