<p dir="auto"><strong>Is this a request for help?</strong> (If yes, you should use our troubleshooting guide and community support channels, see <a href="http://kubernetes.io/docs/troubleshooting/" rel="nofollow">http://kubernetes.io/docs/troubleshooting/</a>.):</p>
<p dir="auto">No</p>
<p dir="auto"><strong>What keywords did you search in Kubernetes issues before filing this one?</strong> (If you have found any duplicates, you should instead reply there.):</p>
<p dir="auto">openstack swift<br>
openstack swift_server_url</p>
<hr>
<p dir="auto"><strong>Is this a BUG REPORT or FEATURE REQUEST?</strong> (choose one):</p>
<p dir="auto">BUG REPORT</p>

<p dir="auto"><strong>Kubernetes version</strong> (use <code class="notranslate">kubectl version</code>):</p>
<p dir="auto">v1.4.3</p>
<p dir="auto"><strong>Environment</strong>:</p>
<ul dir="auto">
<li><strong>Cloud provider or hardware configuration</strong>:</li>
</ul>
<p dir="auto">OVH / OpenStack</p>
<ul dir="auto">
<li><strong>OS</strong> (e.g. from /etc/os-release):</li>
</ul>
<p dir="auto">NAME="Ubuntu"<br>
VERSION="16.04.1 LTS (Xenial Xerus)"<br>
ID=ubuntu<br>
ID_LIKE=debian<br>
PRETTY_NAME="Ubuntu 16.04.1 LTS"<br>
VERSION_ID="16.04"<br>
HOME_URL="<a href="http://www.ubuntu.com/" rel="nofollow">http://www.ubuntu.com/</a>"<br>
SUPPORT_URL="<a href="http://help.ubuntu.com/" rel="nofollow">http://help.ubuntu.com/</a>"<br>
BUG_REPORT_URL="<a href="http://bugs.launchpad.net/ubuntu/" rel="nofollow">http://bugs.launchpad.net/ubuntu/</a>"<br>
UBUNTU_CODENAME=xenial</p>
<ul dir="auto">
<li><strong>Kernel</strong> (e.g. <code class="notranslate">uname -a</code>):</li>
</ul>
<p dir="auto">Linux my-laptop 4.4.0-42-generic <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="35512112" data-permission-text="Title is private" data-url="https://github.com/kubernetes/kubernetes/issues/62" data-hovercard-type="issue" data-hovercard-url="/kubernetes/kubernetes/issues/62/hovercard" href="https://github.com/kubernetes/kubernetes/issues/62">#62</a>-Ubuntu SMP Fri Oct 7 23:11:45 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux</p>
<ul dir="auto">
<li><strong>Install tools</strong>:</li>
<li><strong>Others</strong>:</li>
</ul>
<p dir="auto"><strong>What happened</strong>:</p>
<p dir="auto">Running ./cluster/kube-up.sh raises an error with:</p>
<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="usage: openstack stack create [-h] [-f {json,shell,table,value,yaml}]
                              [-c COLUMN] [--max-width &lt;integer&gt;] [--noindent]
                              [--prefix PREFIX] [-e &lt;environment&gt;]
                              [--timeout &lt;timeout&gt;] [--pre-create &lt;resource&gt;]
                              [--enable-rollback] [--parameter &lt;key=value&gt;]
                              [--parameter-file &lt;key=file&gt;] [--wait]
                              [--tags &lt;tag1,tag2...&gt;] [--dry-run] -t
                              &lt;template&gt;
                              &lt;stack-name&gt;
openstack stack create: error: unrecognized arguments: https://storage.sbg1.cloud.ovh.net/v1/AUTH_123456789/kubernetes/kubernetes-salt.tar.gz https://storage.bhs1.cloud.ovh.net/v1/AUTH_123456789 https://storage.sbg1.cloud.ovh.net/v1/AUTH_123456789/kubernetes/kubernetes-server.tar.gz KubernetesStack"><pre class="notranslate">usage: openstack stack create [-h] [-f {json,shell,table,value,yaml}]
                              [-c COLUMN] [--max-width <span class="pl-k">&lt;</span>integer<span class="pl-k">&gt;</span>] [--noindent]
                              [--prefix PREFIX] [-e <span class="pl-k">&lt;</span>environment<span class="pl-k">&gt;</span>]
                              [--timeout <span class="pl-k">&lt;</span>timeout<span class="pl-k">&gt;</span>] [--pre-create <span class="pl-k">&lt;</span>resource<span class="pl-k">&gt;</span>]
                              [--enable-rollback] [--parameter <span class="pl-k">&lt;</span>key<span class="pl-k">=</span>value<span class="pl-k">&gt;</span>]
                              [--parameter-file <span class="pl-k">&lt;</span>key<span class="pl-k">=</span>file<span class="pl-k">&gt;</span>] [--wait]
                              [--tags <span class="pl-k">&lt;</span>tag1,tag2...<span class="pl-k">&gt;</span>] [--dry-run] -t
                              <span class="pl-k">&lt;</span>template<span class="pl-k">&gt;</span>
                              <span class="pl-k">&lt;</span>stack-name<span class="pl-k">&gt;</span>
openstack stack create: error: unrecognized arguments: https://storage.sbg1.cloud.ovh.net/v1/AUTH_123456789/kubernetes/kubernetes-salt.tar.gz https://storage.bhs1.cloud.ovh.net/v1/AUTH_123456789 https://storage.sbg1.cloud.ovh.net/v1/AUTH_123456789/kubernetes/kubernetes-server.tar.gz KubernetesStack</pre></div>
<p dir="auto"><strong>What you expected to happen</strong>:</p>
<p dir="auto">The command to succeed!</p>
<p dir="auto"><strong>How to reproduce it</strong> (as minimally and precisely as possible):</p>
<p dir="auto">You probably need a setup on OVH which is not very minimal…However see below.</p>
<p dir="auto"><strong>Anything else do we need to know</strong>:</p>
<p dir="auto">I've investigated a bit and found that the bug came from <code class="notranslate">cluster/openstack-heat/util.sh</code> trying to automatically detect swift url as it wasn't specified. For that it uses the command <code class="notranslate">openstack catalog show object-store</code> which, in my case, returns three results. I think a simple fix would be to only get the first one by piping <code class="notranslate">head -n 1</code></p>
<div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="SWIFT_SERVER_URL=$(openstack catalog show object-store --format value | egrep -o &quot;publicURL: (.+)$&quot; | cut -d&quot; &quot; -f2 | head -n 1)"><pre class="notranslate">SWIFT_SERVER_URL=<span class="pl-s"><span class="pl-pds">$(</span>openstack catalog show object-store --format value <span class="pl-k">|</span> egrep -o <span class="pl-s"><span class="pl-pds">"</span>publicURL: (.+)$<span class="pl-pds">"</span></span> <span class="pl-k">|</span> cut -d<span class="pl-s"><span class="pl-pds">"</span> <span class="pl-pds">"</span></span> -f2 <span class="pl-k">|</span> head -n 1<span class="pl-pds">)</span></span></pre></div>
<p dir="auto">If that sounds good to you, I'll send a PR.</p>
<p dir="auto">We have a number of tests which randomize values for API types, and each of them has their own table of functions for "special types" that have limited valid values.</p>
<p dir="auto">pkg/api/serialization_test.go<br>
pkg/api/validation/schema_test.go<br>
pkg/api/latest/latest_test.go</p>
<p dir="auto">These should all get folded together.</p>