此内容没有您所选择的语言版本。
Chapter 8. Issues on Microsoft Windows
This section describes CDK issues that affect users on a Microsoft Windows host.
8.1. System tray icon does not reflect profile status 复制链接链接已复制到粘贴板!
The system tray icon (introduced as a Technology Preview feature in Container Development Kit 3.7) does not show profile status. There is no workaround available.
The experimental static IP feature is not possible with the Default Switch provided by Windows. The minishift
virtual machine will receive an IP address, but network traffic will not be able to pass through it.
See Assign IP Address to Hyper-V for more information about how to assign a static IP address to the minishift
VM on Windows.
Windows Command Prompt and PowerShell have problems with parsing JSON into the minishift openshift config set
command. Special attention is required when using this command on Windows.
The workaround for Windows Command Prompt environments is to escape the quotes so that the JSON content is correctly parsed:
minishift.exe openshift config set --patch "{\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}}"
C:\Users\CDK> minishift.exe openshift config set --patch "{\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}}"
The workaround for Windows PowerShell environments is to use a variable to store the JSON content:
PS C:\Users\CDK> $json='{\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}}' PS C:\Users\CDK> echo $json {\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}} PS C:\Users\CDK> minishift.exe openshift config set --patch $json Patching OpenShift configuration /var/lib/origin/openshift.local.config/master/master-config.yaml with {"routingConfig": {"subdomain": "192.168.99.101.nip.io"}}
PS C:\Users\CDK> $json='{\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}}'
PS C:\Users\CDK> echo $json
{\"routingConfig\": {\"subdomain\": \"192.168.99.101.nip.io\"}}
PS C:\Users\CDK> minishift.exe openshift config set --patch $json
Patching OpenShift configuration /var/lib/origin/openshift.local.config/master/master-config.yaml with {"routingConfig": {"subdomain": "192.168.99.101.nip.io"}}
The reason for this failure is currently unknown.
Workaround: Configure the OpenShift cluster from inside of the provisioned VM using minishift ssh
:
minishift.exe ssh
C:\Users\CDK> minishift.exe ssh
[docker@minishift ~]$ docker exec -t origin /usr/bin/openshift ex config patch /var/lib/origin/openshift.local.config/master/master-config.yaml --patch='<json-to-be-applied-to-the-cluster>'
Additional resources
- See the Container Development Kit Getting Started Guide for an overview of Container Development Kit features and an introduction to the use of the Docker service and OpenShift Container Platform.
- Report issues with Red Hat Container Development Kit or request new features using the CDK project at https://issues.jboss.org/projects/CDK.