Sync docs from 2.1.x to gh-pages
This commit is contained in:
@@ -314,7 +314,10 @@ When <code class="literal">myApp</code> has the <code class="literal">dev</code>
|
||||
You can use resources with these file names to configure global defaults and have them be overridden by application-specific files as necessary.</p><p>The #_property_overrides[property overrides] feature can also be used for setting global defaults, with placeholders applications
|
||||
allowed to override them locally.</p><div class="tip" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Tip"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Tip]" src="images/tip.png"></td><th align="left">Tip</th></tr><tr><td align="left" valign="top"><p>With the <span class="quote">“<span class="quote">native</span>”</span> profile (a local file system backend) , you should use an explicit search location that is not part of the server’s own configuration.
|
||||
Otherwise, the <code class="literal">application*</code> resources in the default search locations get removed because they are part of the server.</p></td></tr></table></div></div><div class="section"><div class="titlepage"><div><div><h4 class="title"><a name="spring-cloud-config-server-vault-server" href="#spring-cloud-config-server-vault-server"></a>Vault Server</h4></div></div></div><p>When using Vault as a backend, you can share configuration with all applications by placing configuration in <code class="literal">secret/application</code>.
|
||||
For example, if you run the following Vault command, all applications using the config server will have the properties <code class="literal">foo</code> and <code class="literal">baz</code> available to them:</p><pre class="programlisting">$ vault write secret/application foo=bar baz=bam</pre></div></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="_jdbc_backend" href="#_jdbc_backend"></a>2.1.7 JDBC Backend</h3></div></div></div><p>Spring Cloud Config Server supports JDBC (relational database) as a backend for configuration properties.
|
||||
For example, if you run the following Vault command, all applications using the config server will have the properties <code class="literal">foo</code> and <code class="literal">baz</code> available to them:</p><pre class="programlisting">$ vault write secret/application foo=bar baz=bam</pre></div><div class="section"><div class="titlepage"><div><div><h4 class="title"><a name="_credhub_server" href="#_credhub_server"></a>CredHub Server</h4></div></div></div><p>When using CredHub as a backend, you can share configuration with all applications by placing configuration in <code class="literal">/application/</code> or by placing it in the <code class="literal">default</code> profile for the application.
|
||||
For example, if you run the following CredHub command, all applications using the config server will have the properties <code class="literal">shared.color1</code> and <code class="literal">shared.color2</code> available to them:</p><pre class="programlisting">credhub set --name "/application/profile/master/shared" --type=json
|
||||
value: {"shared.color1": "blue", "shared.color": "red"}</pre><pre class="programlisting">credhub set --name "/my-app/default/master/more-shared" --type=json
|
||||
value: {"shared.word1": "hello", "shared.word2": "world"}</pre></div></div><div class="section"><div class="titlepage"><div><div><h3 class="title"><a name="_jdbc_backend" href="#_jdbc_backend"></a>2.1.7 JDBC Backend</h3></div></div></div><p>Spring Cloud Config Server supports JDBC (relational database) as a backend for configuration properties.
|
||||
You can enable this feature by adding <code class="literal">spring-jdbc</code> to the classpath and using the <code class="literal">jdbc</code> profile or by adding a bean of type <code class="literal">JdbcEnvironmentRepository</code>.
|
||||
If you include the right dependencies on the classpath (see the user guide for more details on that), Spring Boot configures a data source.</p><p>The database needs to have a table called <code class="literal">PROPERTIES</code> with columns called <code class="literal">APPLICATION</code>, <code class="literal">PROFILE</code>, and <code class="literal">LABEL</code> (with the usual <code class="literal">Environment</code> meaning), plus <code class="literal">KEY</code> and <code class="literal">VALUE</code> for the key and value pairs in <code class="literal">Properties</code> style.
|
||||
All fields are of type String in Java, so you can make them <code class="literal">VARCHAR</code> of whatever length you need.
|
||||
@@ -340,7 +343,8 @@ value: {"marketing.enabled": true, "external.enabled": false}</pre><p>All client
|
||||
toggle.link: "red",
|
||||
marketing.enabled: true,
|
||||
external.enabled: false
|
||||
}</pre><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="images/note.png"></td><th align="left">Note</th></tr><tr><td align="left" valign="top"><p>When no profile is specified <code class="literal">default</code> will be used and when no label is specified <code class="literal">master</code> will be used as a default value.</p></td></tr></table></div><div class="section"><div class="titlepage"><div><div><h4 class="title"><a name="_oauth_2_0" href="#_oauth_2_0"></a>OAuth 2.0</h4></div></div></div><p>You can authenticate with <a class="link" href="https://oauth.net/2/" target="_top">OAuth 2.0</a> using <a class="link" href="https://docs.cloudfoundry.org/concepts/architecture/uaa.html" target="_top">UAA</a> as a provider.</p><p><b>pom.xml. </b>
|
||||
}</pre><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="images/note.png"></td><th align="left">Note</th></tr><tr><td align="left" valign="top"><p>When no profile is specified <code class="literal">default</code> will be used and when no label is specified <code class="literal">master</code> will be used as a default value.
|
||||
NOTE: Values added to <code class="literal">application</code> will be shared by all the applications.</p></td></tr></table></div><div class="section"><div class="titlepage"><div><div><h4 class="title"><a name="_oauth_2_0" href="#_oauth_2_0"></a>OAuth 2.0</h4></div></div></div><p>You can authenticate with <a class="link" href="https://oauth.net/2/" target="_top">OAuth 2.0</a> using <a class="link" href="https://docs.cloudfoundry.org/concepts/architecture/uaa.html" target="_top">UAA</a> as a provider.</p><p><b>pom.xml. </b>
|
||||
</p><pre class="programlisting"><span xmlns:d="http://docbook.org/ns/docbook" class="hl-tag"><dependencies></span>
|
||||
<span xmlns:d="http://docbook.org/ns/docbook" class="hl-tag"><dependency></span>
|
||||
<span xmlns:d="http://docbook.org/ns/docbook" class="hl-tag"><groupId></span>org.springframework.security<span xmlns:d="http://docbook.org/ns/docbook" class="hl-tag"></groupId></span>
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -811,6 +811,15 @@ Otherwise, the <literal>application*</literal> resources in the default search l
|
||||
For example, if you run the following Vault command, all applications using the config server will have the properties <literal>foo</literal> and <literal>baz</literal> available to them:</simpara>
|
||||
<programlisting language="sh" linenumbering="unnumbered">$ vault write secret/application foo=bar baz=bam</programlisting>
|
||||
</section>
|
||||
<section xml:id="_credhub_server">
|
||||
<title>CredHub Server</title>
|
||||
<simpara>When using CredHub as a backend, you can share configuration with all applications by placing configuration in <literal>/application/</literal> or by placing it in the <literal>default</literal> profile for the application.
|
||||
For example, if you run the following CredHub command, all applications using the config server will have the properties <literal>shared.color1</literal> and <literal>shared.color2</literal> available to them:</simpara>
|
||||
<programlisting language="sh" linenumbering="unnumbered">credhub set --name "/application/profile/master/shared" --type=json
|
||||
value: {"shared.color1": "blue", "shared.color": "red"}</programlisting>
|
||||
<programlisting language="sh" linenumbering="unnumbered">credhub set --name "/my-app/default/master/more-shared" --type=json
|
||||
value: {"shared.word1": "hello", "shared.word2": "world"}</programlisting>
|
||||
</section>
|
||||
</section>
|
||||
<section xml:id="_jdbc_backend">
|
||||
<title>JDBC Backend</title>
|
||||
@@ -858,7 +867,8 @@ value: {"marketing.enabled": true, "external.enabled": false}</programlisting>
|
||||
external.enabled: false
|
||||
}</screen>
|
||||
<note>
|
||||
<simpara>When no profile is specified <literal>default</literal> will be used and when no label is specified <literal>master</literal> will be used as a default value.</simpara>
|
||||
<simpara>When no profile is specified <literal>default</literal> will be used and when no label is specified <literal>master</literal> will be used as a default value.
|
||||
NOTE: Values added to <literal>application</literal> will be shared by all the applications.</simpara>
|
||||
</note>
|
||||
<section xml:id="_oauth_2_0">
|
||||
<title>OAuth 2.0</title>
|
||||
|
||||
Reference in New Issue
Block a user