1. 配置用户(在 Master 上操作)
安装 httpd-tools
yum -y install httpd-tools;
创建一个 admin 用户,并且赋予权限
htpasswd -cb /etc/origin/master/htpasswd admin redhat;
oadm policy add-cluster-role-to-user admin admin
2. 配置二级域名(在 Master 上操作)
cp /etc/origin/master/master-config.yaml /etc/origin/master/master-config.yaml.bak.$(date "+%Y%m%d%H%M%S");
sed -i 's/.*subdomain.*/ subdomain: apps.example.com/' /etc/origin/master/master-config.yaml;
3. 重启 OpenShift,使上述修改生效(在 Master 上操作)
systemctl restart atomic-openshift-{master,node};
4. 如果之前自动安装 Registry Console 失败,以下手动重新安装
4.1 之前自动安装 Registry Console 有错,执行以下命令清除
oc delete dc registry-console
oc delete svc registry-console
oc delete route registry-console
oc delete is registry-console
oc delete oauthclients cockpit-oauth-client
4.2 创建 registry-console route
oc create route passthrough --service registry-console --port registry-console -n default
4.3 部署 registry console 应用
oc new-app -n default --template=registry-console \
-p IMAGE_PREFIX="registry.example.com:5000/openshift3/" \
-p IMAGE_VERSION="3.5" \
-p OPENSHIFT_OAUTH_PROVIDER_URL="https://master.example.com:8443" \
-p REGISTRY_HOST=$(oc get route docker-registry -n default --template='{{ .spec.host }}') \
-p COCKPIT_KUBE_URL=$(oc get route registry-console -n default --template='https://{{ .spec.host }}')
5. 添加 Image Stream(在 Master 上操作)
5.1 查看当前的 Image Stream
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.1,1.0
fis-java-openshift registry.access.redhat.com/jboss-fuse-6/fis-java-openshift
fis-karaf-openshift registry.access.redhat.com/jboss-fuse-6/fis-karaf-openshift
jboss-amq-62 registry.access.redhat.com/jboss-amq-6/amq62-openshift
jboss-datagrid65-openshift registry.access.redhat.com/jboss-datagrid-6/datagrid65-openshift
jboss-datavirt63-openshift registry.access.redhat.com/jboss-datavirt-6/datavirt63-openshift
jboss-decisionserver62-openshift registry.access.redhat.com/jboss-decisionserver-6/decisionserver62-openshift
jboss-decisionserver63-openshift registry.access.redhat.com/jboss-decisionserver-6/decisionserver63-openshift
jboss-eap64-openshift registry.access.redhat.com/jboss-eap-6/eap64-openshift
jboss-eap70-openshift registry.access.redhat.com/jboss-eap-7/eap70-openshift
jboss-processserver63-openshift registry.access.redhat.com/jboss-processserver-6/processserver63-openshift
jboss-webserver30-tomcat7-openshift registry.access.redhat.com/jboss-webserver-3/webserver30-tomcat7-openshift
jboss-webserver30-tomcat8-openshift registry.access.redhat.com/jboss-webserver-3/webserver30-tomcat8-openshift
jenkins 172.30.132.67:5000/openshift/jenkins 2,1
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb 3.2,2.6,2.4
mysql 172.30.132.67:5000/openshift/mysql 5.7,5.6,5.5
nodejs 172.30.132.67:5000/openshift/nodejs 0.10,4
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php 7.0,5.6,5.5
postgresql 172.30.132.67:5000/openshift/postgresql 9.4,9.2,9.5
python 172.30.132.67:5000/openshift/python 3.5,3.4,3.3 + 1 more...
redhat-openjdk18-openshift registry.access.redhat.com/redhat-openjdk-18/openjdk18-openshift
redhat-sso70-openshift registry.access.redhat.com/redhat-sso-7/sso70-openshift
redis 172.30.132.67:5000/openshift/redis 3.2
ruby 172.30.132.67:5000/openshift/ruby 2.3,2.2,2.0
5.2 删除原有的 Image Stream
for i in $(oc get is -n openshift --no-headers|awk '{print $1}') ; do oc delete is $i -n openshift; done;
5.3 创建指向本地 Docker Registry 的 Image Stream
REDHAT_REG="registry.access.redhat.com";
PRIVATE_REG="registry.example.com:5000";
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/image-streams/image-streams-rhel7.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/xpaas-streams/jboss-image-streams.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/image-streams/dotnet_imagestreams.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
5.4 再次查看 Image Stream
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.0,1.1
jboss-amq-62 registry.example.com:5000/jboss-amq-6/amq62-openshift
jboss-datagrid65-openshift registry.example.com:5000/jboss-datagrid-6/datagrid65-openshift
jboss-datavirt63-openshift registry.example.com:5000/jboss-datavirt-6/datavirt63-openshift
jboss-decisionserver62-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver62-openshift
jboss-decisionserver63-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver63-openshift
jboss-eap64-openshift registry.example.com:5000/jboss-eap-6/eap64-openshift
jboss-eap70-openshift registry.example.com:5000/jboss-eap-7/eap70-openshift
jboss-processserver63-openshift registry.example.com:5000/jboss-processserver-6/processserver63-openshift
jboss-webserver30-tomcat7-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat7-openshift
jboss-webserver30-tomcat8-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat8-openshift
jenkins 172.30.132.67:5000/openshift/jenkins 1,2
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb 3.2,2.6,2.4
mysql 172.30.132.67:5000/openshift/mysql 5.5,5.7,5.6
nodejs 172.30.132.67:5000/openshift/nodejs 4,0.10
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php 5.6,5.5,7.0
postgresql 172.30.132.67:5000/openshift/postgresql 9.5,9.4,9.2
python 172.30.132.67:5000/openshift/python 3.4,3.3,2.7 + 1 more...
redhat-openjdk18-openshift registry.example.com:5000/redhat-openjdk-18/openjdk18-openshift
redhat-sso70-openshift registry.example.com:5000/redhat-sso-7/sso70-openshift
redis 172.30.132.67:5000/openshift/redis 3.2
ruby 172.30.132.67:5000/openshift/ruby 2.3,2.2,2.0
5.5 导入列表中所有 Image
可以看到有些 Image Stream 没有 Tag,需要导入 Image
for i in $(oc get is -n openshift --no-headers|awk '{print $1}'); do oc import-image $i --insecure --all -n openshift;done
注意,不是所有的 image 都能导入成功,这个跟导入的 Image 有关。
如果没有该 Image,是无法成功导入 Image Stream 的。
并且,一个软件有很多版本的 Image,导入了哪个 Image,哪个 Image Stream Tag 才能导入成功。
比如 mysql 这个 Image 我导入了 5.7 和 5.6 版本,在执行 oc import-image 时,会报告 5.7 和 5.6 成功导入,而 5.5 没有导入成功。
oc import-image mysql --insecure -n openshift
输出如下:
The import completed successfully.
Name: mysql
Namespace: openshift
Created: 3 minutes ago
Labels: <none>
Annotations: openshift.io/display-name=MySQL
openshift.io/image.dockerRepositoryCheck=2017-05-24T10:12:33Z
Docker Pull Spec: 172.30.132.67:5000/openshift/mysql
Unique Images: 2
Tags: 4
5.7 (latest)
tagged from registry.example.com:5000/rhscl/mysql-57-rhel7:latest
will use insecure HTTPS or HTTP connections
Provides a MySQL 5.7 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.7/README.md.
Tags: mysql
* registry.example.com:5000/rhscl/mysql-57-rhel7@sha256:bcec20eec2b4292ba3e0ba91e05f07b1dd8f04f4fda2eaf1e32e947f613975a4
2 minutes ago
5.6
tagged from registry.example.com:5000/rhscl/mysql-56-rhel7:latest
will use insecure HTTPS or HTTP connections
Provides a MySQL 5.6 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.6/README.md.
Tags: mysql
* registry.example.com:5000/rhscl/mysql-56-rhel7@sha256:cd7981a6fab1f9ac08ee60348b9c79badbb32a858ead07198eb5a493cc13c741
2 minutes ago
5.5
tagged from registry.example.com:5000/openshift3/mysql-55-rhel7:latest
Provides a MySQL 5.5 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.5/README.md.
Tags: hidden, mysql
! error: Import failed (NotFound): dockerimage "registry.example.com:5000/openshift3/mysql-55-rhel7:latest" not found
2 minutes ago
5.6 再次查看 Image Stream
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.1,1.0
jboss-amq-62 registry.example.com:5000/jboss-amq-6/amq62-openshift latest 18 seconds ago
jboss-datagrid65-openshift registry.example.com:5000/jboss-datagrid-6/datagrid65-openshift latest
jboss-datavirt63-openshift registry.example.com:5000/jboss-datavirt-6/datavirt63-openshift latest
jboss-decisionserver62-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver62-openshift latest
jboss-decisionserver63-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver63-openshift latest 17 seconds ago
jboss-eap64-openshift registry.example.com:5000/jboss-eap-6/eap64-openshift latest 17 seconds ago
jboss-eap70-openshift registry.example.com:5000/jboss-eap-7/eap70-openshift latest 17 seconds ago
jboss-processserver63-openshift registry.example.com:5000/jboss-processserver-6/processserver63-openshift latest 17 seconds ago
jboss-webserver30-tomcat7-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat7-openshift latest 16 seconds ago
jboss-webserver30-tomcat8-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat8-openshift latest 16 seconds ago
jenkins 172.30.132.67:5000/openshift/jenkins latest,2,1 16 seconds ago
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb latest,3.2,2.4 + 1 more... 16 seconds ago
mysql 172.30.132.67:5000/openshift/mysql latest,5.7,5.6 + 1 more... 15 seconds ago
nodejs 172.30.132.67:5000/openshift/nodejs 0.10,4
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php latest,7.0,5.6 + 1 more... 15 seconds ago
postgresql 172.30.132.67:5000/openshift/postgresql 9.4,9.2,9.5
python 172.30.132.67:5000/openshift/python latest,3.5,3.4 + 2 more... 15 seconds ago
redhat-openjdk18-openshift registry.example.com:5000/redhat-openjdk-18/openjdk18-openshift latest
redhat-sso70-openshift registry.example.com:5000/redhat-sso-7/sso70-openshift latest
redis 172.30.132.67:5000/openshift/redis latest,3.2 14 seconds ago
ruby 172.30.132.67:5000/openshift/ruby latest,2.3,2.2 + 1 more... 14 seconds ago
6. 访问 OpenShift 控制台
https://master.example.com:8443 admin/redhat
安装 httpd-tools
yum -y install httpd-tools;
创建一个 admin 用户,并且赋予权限
htpasswd -cb /etc/origin/master/htpasswd admin redhat;
oadm policy add-cluster-role-to-user admin admin
cp /etc/origin/master/master-config.yaml /etc/origin/master/master-config.yaml.bak.$(date "+%Y%m%d%H%M%S");
sed -i 's/.*subdomain.*/ subdomain: apps.example.com/' /etc/origin/master/master-config.yaml;
3. 重启 OpenShift,使上述修改生效(在 Master 上操作)
systemctl restart atomic-openshift-{master,node};
4. 如果之前自动安装 Registry Console 失败,以下手动重新安装
4.1 之前自动安装 Registry Console 有错,执行以下命令清除
oc delete dc registry-console
oc delete svc registry-console
oc delete route registry-console
oc delete is registry-console
oc delete oauthclients cockpit-oauth-client
4.2 创建 registry-console route
oc create route passthrough --service registry-console --port registry-console -n default
4.3 部署 registry console 应用
oc new-app -n default --template=registry-console \
-p IMAGE_PREFIX="registry.example.com:5000/openshift3/" \
-p IMAGE_VERSION="3.5" \
-p OPENSHIFT_OAUTH_PROVIDER_URL="https://master.example.com:8443" \
-p REGISTRY_HOST=$(oc get route docker-registry -n default --template='{{ .spec.host }}') \
-p COCKPIT_KUBE_URL=$(oc get route registry-console -n default --template='https://{{ .spec.host }}')
5. 添加 Image Stream(在 Master 上操作)
5.1 查看当前的 Image Stream
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.1,1.0
fis-java-openshift registry.access.redhat.com/jboss-fuse-6/fis-java-openshift
fis-karaf-openshift registry.access.redhat.com/jboss-fuse-6/fis-karaf-openshift
jboss-amq-62 registry.access.redhat.com/jboss-amq-6/amq62-openshift
jboss-datagrid65-openshift registry.access.redhat.com/jboss-datagrid-6/datagrid65-openshift
jboss-datavirt63-openshift registry.access.redhat.com/jboss-datavirt-6/datavirt63-openshift
jboss-decisionserver62-openshift registry.access.redhat.com/jboss-decisionserver-6/decisionserver62-openshift
jboss-decisionserver63-openshift registry.access.redhat.com/jboss-decisionserver-6/decisionserver63-openshift
jboss-eap64-openshift registry.access.redhat.com/jboss-eap-6/eap64-openshift
jboss-eap70-openshift registry.access.redhat.com/jboss-eap-7/eap70-openshift
jboss-processserver63-openshift registry.access.redhat.com/jboss-processserver-6/processserver63-openshift
jboss-webserver30-tomcat7-openshift registry.access.redhat.com/jboss-webserver-3/webserver30-tomcat7-openshift
jboss-webserver30-tomcat8-openshift registry.access.redhat.com/jboss-webserver-3/webserver30-tomcat8-openshift
jenkins 172.30.132.67:5000/openshift/jenkins 2,1
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb 3.2,2.6,2.4
mysql 172.30.132.67:5000/openshift/mysql 5.7,5.6,5.5
nodejs 172.30.132.67:5000/openshift/nodejs 0.10,4
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php 7.0,5.6,5.5
postgresql 172.30.132.67:5000/openshift/postgresql 9.4,9.2,9.5
python 172.30.132.67:5000/openshift/python 3.5,3.4,3.3 + 1 more...
redhat-openjdk18-openshift registry.access.redhat.com/redhat-openjdk-18/openjdk18-openshift
redhat-sso70-openshift registry.access.redhat.com/redhat-sso-7/sso70-openshift
redis 172.30.132.67:5000/openshift/redis 3.2
ruby 172.30.132.67:5000/openshift/ruby 2.3,2.2,2.0
for i in $(oc get is -n openshift --no-headers|awk '{print $1}') ; do oc delete is $i -n openshift; done;
5.3 创建指向本地 Docker Registry 的 Image Stream
REDHAT_REG="registry.access.redhat.com";
PRIVATE_REG="registry.example.com:5000";
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/image-streams/image-streams-rhel7.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/xpaas-streams/jboss-image-streams.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
sed s/"${REDHAT_REG}"/"${PRIVATE_REG}"/g /usr/share/openshift/examples/image-streams/dotnet_imagestreams.json |sed '/"creationTimestamp": null/a\\t,"annotations": {"openshift.io/image.insecureRepository": "true"}' |oc create -n openshift -f - ;
5.4 再次查看 Image Stream
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.0,1.1
jboss-amq-62 registry.example.com:5000/jboss-amq-6/amq62-openshift
jboss-datagrid65-openshift registry.example.com:5000/jboss-datagrid-6/datagrid65-openshift
jboss-datavirt63-openshift registry.example.com:5000/jboss-datavirt-6/datavirt63-openshift
jboss-decisionserver62-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver62-openshift
jboss-decisionserver63-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver63-openshift
jboss-eap64-openshift registry.example.com:5000/jboss-eap-6/eap64-openshift
jboss-eap70-openshift registry.example.com:5000/jboss-eap-7/eap70-openshift
jboss-processserver63-openshift registry.example.com:5000/jboss-processserver-6/processserver63-openshift
jboss-webserver30-tomcat7-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat7-openshift
jboss-webserver30-tomcat8-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat8-openshift
jenkins 172.30.132.67:5000/openshift/jenkins 1,2
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb 3.2,2.6,2.4
mysql 172.30.132.67:5000/openshift/mysql 5.5,5.7,5.6
nodejs 172.30.132.67:5000/openshift/nodejs 4,0.10
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php 5.6,5.5,7.0
postgresql 172.30.132.67:5000/openshift/postgresql 9.5,9.4,9.2
python 172.30.132.67:5000/openshift/python 3.4,3.3,2.7 + 1 more...
redhat-openjdk18-openshift registry.example.com:5000/redhat-openjdk-18/openjdk18-openshift
redhat-sso70-openshift registry.example.com:5000/redhat-sso-7/sso70-openshift
redis 172.30.132.67:5000/openshift/redis 3.2
ruby 172.30.132.67:5000/openshift/ruby 2.3,2.2,2.0
5.5 导入列表中所有 Image
可以看到有些 Image Stream 没有 Tag,需要导入 Image
for i in $(oc get is -n openshift --no-headers|awk '{print $1}'); do oc import-image $i --insecure --all -n openshift;done
注意,不是所有的 image 都能导入成功,这个跟导入的 Image 有关。
如果没有该 Image,是无法成功导入 Image Stream 的。
并且,一个软件有很多版本的 Image,导入了哪个 Image,哪个 Image Stream Tag 才能导入成功。
比如 mysql 这个 Image 我导入了 5.7 和 5.6 版本,在执行 oc import-image 时,会报告 5.7 和 5.6 成功导入,而 5.5 没有导入成功。
oc import-image mysql --insecure -n openshift
输出如下:
The import completed successfully.
Name: mysql
Namespace: openshift
Created: 3 minutes ago
Labels: <none>
Annotations: openshift.io/display-name=MySQL
openshift.io/image.dockerRepositoryCheck=2017-05-24T10:12:33Z
Docker Pull Spec: 172.30.132.67:5000/openshift/mysql
Unique Images: 2
Tags: 4
5.7 (latest)
tagged from registry.example.com:5000/rhscl/mysql-57-rhel7:latest
will use insecure HTTPS or HTTP connections
Provides a MySQL 5.7 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.7/README.md.
Tags: mysql
* registry.example.com:5000/rhscl/mysql-57-rhel7@sha256:bcec20eec2b4292ba3e0ba91e05f07b1dd8f04f4fda2eaf1e32e947f613975a4
2 minutes ago
5.6
tagged from registry.example.com:5000/rhscl/mysql-56-rhel7:latest
will use insecure HTTPS or HTTP connections
Provides a MySQL 5.6 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.6/README.md.
Tags: mysql
* registry.example.com:5000/rhscl/mysql-56-rhel7@sha256:cd7981a6fab1f9ac08ee60348b9c79badbb32a858ead07198eb5a493cc13c741
2 minutes ago
5.5
tagged from registry.example.com:5000/openshift3/mysql-55-rhel7:latest
Provides a MySQL 5.5 database on RHEL 7. For more information about using this database image, including OpenShift considerations, see https://github.com/sclorg/mysql-container/tree/master/5.5/README.md.
Tags: hidden, mysql
! error: Import failed (NotFound): dockerimage "registry.example.com:5000/openshift3/mysql-55-rhel7:latest" not found
2 minutes ago
oc get is -n openshift
输出如下:
NAME DOCKER REPO TAGS UPDATED
dotnet 172.30.132.67:5000/openshift/dotnet 1.1,1.0
jboss-amq-62 registry.example.com:5000/jboss-amq-6/amq62-openshift latest 18 seconds ago
jboss-datagrid65-openshift registry.example.com:5000/jboss-datagrid-6/datagrid65-openshift latest
jboss-datavirt63-openshift registry.example.com:5000/jboss-datavirt-6/datavirt63-openshift latest
jboss-decisionserver62-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver62-openshift latest
jboss-decisionserver63-openshift registry.example.com:5000/jboss-decisionserver-6/decisionserver63-openshift latest 17 seconds ago
jboss-eap64-openshift registry.example.com:5000/jboss-eap-6/eap64-openshift latest 17 seconds ago
jboss-eap70-openshift registry.example.com:5000/jboss-eap-7/eap70-openshift latest 17 seconds ago
jboss-processserver63-openshift registry.example.com:5000/jboss-processserver-6/processserver63-openshift latest 17 seconds ago
jboss-webserver30-tomcat7-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat7-openshift latest 16 seconds ago
jboss-webserver30-tomcat8-openshift registry.example.com:5000/jboss-webserver-3/webserver30-tomcat8-openshift latest 16 seconds ago
jenkins 172.30.132.67:5000/openshift/jenkins latest,2,1 16 seconds ago
mariadb 172.30.132.67:5000/openshift/mariadb 10.1
mongodb 172.30.132.67:5000/openshift/mongodb latest,3.2,2.4 + 1 more... 16 seconds ago
mysql 172.30.132.67:5000/openshift/mysql latest,5.7,5.6 + 1 more... 15 seconds ago
nodejs 172.30.132.67:5000/openshift/nodejs 0.10,4
perl 172.30.132.67:5000/openshift/perl 5.24,5.20,5.16
php 172.30.132.67:5000/openshift/php latest,7.0,5.6 + 1 more... 15 seconds ago
postgresql 172.30.132.67:5000/openshift/postgresql 9.4,9.2,9.5
python 172.30.132.67:5000/openshift/python latest,3.5,3.4 + 2 more... 15 seconds ago
redhat-openjdk18-openshift registry.example.com:5000/redhat-openjdk-18/openjdk18-openshift latest
redhat-sso70-openshift registry.example.com:5000/redhat-sso-7/sso70-openshift latest
redis 172.30.132.67:5000/openshift/redis latest,3.2 14 seconds ago
ruby 172.30.132.67:5000/openshift/ruby latest,2.3,2.2 + 1 more... 14 seconds ago
可以看到有些镜像多了很多版本。
https://master.example.com:8443 admin/redhat
1 条评论:
Hi 您好,
拜讀您的文章,受益良多,但在registry-console部分有個問題想請教:按照您的方式建立了registry-console之後,在oc new-app之後都會出現以下"ImagePullBackOff"的問題:
# oc get pod
NAME READY STATUS RESTARTS AGE
docker-registry-1-vtmhq 1/1 Running 0 2h
registry-console-1-deploy 1/1 Running 0 21s
registry-console-1-h38wp 0/1 ImagePullBackOff 0 18s
router-1-60lg1 1/1 Running 0 2h
使用# oc describe pod registry-console-1-h38wp 後,出現:
Failed to pull image .......this may be because there are no credentials on this request.
可是我直接使用 docker pull image 是ok的,不知道您有沒有碰到過這種的問題?
感謝~~
发表评论