Modified: karaf/site/production/manual/latest/urls.html
URL: 
http://svn.apache.org/viewvc/karaf/site/production/manual/latest/urls.html?rev=1816059&r1=1816058&r2=1816059&view=diff
==============================================================================
--- karaf/site/production/manual/latest/urls.html (original)
+++ karaf/site/production/manual/latest/urls.html Wed Nov 22 14:52:25 2017
@@ -517,7 +517,7 @@ table.CodeRay td.code>pre{padding:0}
 </div>
 <div class="listingblock">
 <div class="content">
-<pre>&lt;bundle&gt;http://repo1.maven.org/maven2/org/apache/servicemix/nmr/org.apache.servicemix.nmr.api/1.0.0-m2/org.apache.servicemix.nmr.api-1.0.0-m2.jar&lt;/bundle&gt;</pre>
+<pre class="CodeRay highlight 
nowrap"><code>&lt;bundle&gt;http://repo1.maven.org/maven2/org/apache/servicemix/nmr/org.apache.servicemix.nmr.api/1.0.0-m2/org.apache.servicemix.nmr.api-1.0.0-m2.jar&lt;/bundle&gt;</code></pre>
 </div>
 </div>
 <div class="paragraph">
@@ -555,35 +555,426 @@ located in a directory which is not avai
 <p>In addition to being less verbose, the Maven url handlers can also resolve 
snapshots and can use a local copy of the jar if one is available in your Maven 
local repository.</p>
 </div>
 <div class="paragraph">
-<p>The <code>org.ops4j.pax.url.mvn</code> bundle resolves <code>mvn</code> 
URLs. It can be configured using the file 
<code>etc/org.ops4j.pax.url.cfg</code></p>
+<p>The <code>org.ops4j.pax.url.mvn</code> bundle resolves <code>mvn</code> 
URLs. It can be configured using the file 
<code>etc/org.ops4j.pax.url.cfg</code>.
+Full reference of <code>org.ops4j.pax.url.mvn</code> PID configuration can be 
found <a 
href="https://ops4j1.jira.com/wiki/display/paxurl/Aether+Configuration";>on 
pax-web Wiki page</a>.</p>
 </div>
 <div class="paragraph">
-<p>The most important property is :</p>
+<p>The most important property is:</p>
 </div>
 <div class="ulist">
 <ul>
 <li>
-<p><code>org.ops4j.pax.url.mvn.repositories</code> : Comma separated list of 
repository remote repository URLs that are checked in order of occurence when 
resolving maven artifacts</p>
+<p><code>org.ops4j.pax.url.mvn.repositories</code> : Comma separated list of 
remote repository URLs that are checked in order of occurence when resolving 
maven artifacts</p>
 </li>
 </ul>
 </div>
 <div class="paragraph">
-<p>By default, snapshots are disabled. To enable an URL for snapshots append 
@snapshots to a repository entry. For example</p>
+<p>Two other significant properties are:</p>
+</div>
+<div class="ulist">
+<ul>
+<li>
+<p><code>org.ops4j.pax.url.mvn.defaulRepositories</code> : Comma separated 
list of locations that are checked before querying remote repositories. These 
can be treated as read-only repositories, as nothing is written there during 
artifact resolution.</p>
+</li>
+<li>
+<p><code>org.ops4j.pax.url.mvn.localRepository</code> : by default 
(implicitly) it&#8217;s standard <code>~/.m2/repository</code> location. This
+local repository is used to store artifacts downloaded from one of remote 
repositories, so at next resolution attempt
+no remote request is issued.</p>
+</li>
+</ul>
+</div>
+<div class="paragraph">
+<p>By default, snapshots are disabled. To enable an URL for snapshots append 
<code>@snapshots</code> to a repository URI. For example</p>
 </div>
 <div class="listingblock">
 <div class="content">
-<pre>http://www.example.org/repo@snapshots</pre>
+<pre>org.ops4j.pax.url.mvn.repositories = 
http://www.example.org/repo@snapshots</pre>
 </div>
 </div>
 <div class="paragraph">
 <p>Repositories on the local machine are supported through <code>file:/</code> 
URLs.</p>
 </div>
 </div>
+<div class="sect3">
+<h4 id="_maven_configuration_commands">Maven configuration commands</h4>
+<div class="paragraph">
+<p>Full configuration of <code>org.ops4j.pax.url.mvn</code> bundle can be done 
using <code>org.ops4j.pax.url.mvn</code> PID (see 
<code>etc/org.ops4j.pax.url.mvn.cfg</code> file). This however may be 
cumbersome in some scenarios.</p>
+</div>
+<div class="paragraph">
+<p>In order to make user&#8217;s life easier and provide more <em>domain</em> 
oriented approach, Karaf provides several shell commands that makes Maven 
configuration easier.</p>
+</div>
+<div class="sect4">
+<h5 id="_maven_summary">maven:summary</h5>
+<div class="paragraph">
+<p>This command shows quick summary about current 
<code>org.ops4j.pax.url.mvn</code> PID configuration. For example:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; maven:summary -s
+
+Option                    │ Value                                            
              │ Source
+──────────────────────────┼────────────────────────────────────────────────────────────────┼──────────────────────────────────────────────────────────────────────────�
 �”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€
+Local repository          │ /home/ggrzybek/.m2/repository                    
              │ Implicit ${user.home}/.m2/repository
+Settings file             │ /home/ggrzybek/.m2/settings.xml                  
              │ Implicit ${user.home}/.m2/settings.xml
+Security settings file    │ /home/ggrzybek/.m2/settings-security.xml         
              │ Implicit ${user.home}/.m2/settings-security.xml
+Global update policy      │                                                  
              │ Implicit "never", but doesn't override repository-specific 
value
+Global checksum policy    │ warn                                             
              │ Default "warn"
+Update releases           │ false                                            
              │ Default "false"
+Require Config Admin      │ true                                             
              │ BundleContext property 
(org.ops4j.pax.url.mvn.requireConfigAdminConfig)
+Use fallback repository   │ false                                            
              │ Explicit org.ops4j.pax.url.mvn PID configuration 
(org.ops4j.pax.url.mvn.useFallbackRepositories)
+Offline mode              │ false                                            
              │ Default "false"
+SSL/TLS certificate check │ true                                             
              │ Explicit org.ops4j.pax.url.mvn PID configuration 
(org.ops4j.pax.url.mvn.certificateCheck)
+Remote repositories       │ http://repo1.maven.org/maven2/                   
              │ PID configuration
+                          │ 
http://repository.apache.org/content/groups/snapshots-group/   │ PID 
configuration
+                          │ 
https://oss.sonatype.org/content/repositories/snapshots/       │ PID 
configuration
+                          │ 
https://oss.sonatype.org/content/repositories/ops4j-snapshots/ │ PID 
configuration
+Default repositories      │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/system/         │ PID 
configuration
+                          │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/kar/       │ PID 
configuration
+HTTP proxies              │ proxy.everfree.forest:3128                       
              │ Maven XML settings</code></pre>
+</div>
+</div>
+<div class="ulist">
+<ul>
+<li>
+<p><code>-s</code> option show where the value of the option come from. It may 
be implicit, explicit or default. We can also see
+whether the value was configured in PID or in <code>settings.xml</code> 
file.</p>
+</li>
+<li>
+<p><code>-p</code> option uses original option names from 
<code>org.ops4j.pax.url.mvn</code> PID instead of descriptive option names</p>
+</li>
+<li>
+<p><code>-d</code> option shows additional description, explaining what given 
option should be used for</p>
+</li>
+<li>
+<p><code>-x</code> option turns on password display - if there&#8217;s master 
password configured, it&#8217;ll be displayed in clear text.
+This option may be used only by user with <code>admin</code> role.</p>
+</li>
+</ul>
+</div>
+</div>
+<div class="sect4">
+<h5 id="_maven_repository_list">maven:repository-list</h5>
+<div class="paragraph">
+<p>This command displays all configured Maven repositories - in much more 
readable way than plain <code>config:proplist --pid 
org.ops4j.pax.url.mvn</code> command does.</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; 
maven:repository-list -v
+
+== Remote repositories
+ID                              │ URL                                        
                    │ Releases    │ Snapshots   │ Defined in
+────────────────────────────────┼────────────────────────────────────────────────────────────────┼─────────────┼─────────────┼───────────
+central                         │ http://repo1.maven.org/maven2/             
                    │ yes (daily) │ no          │ PID
+apache                          │ 
http://repository.apache.org/content/groups/snapshots-group/   │ no          
│ yes (daily) │ PID
+sonatype.snapshots.deploy       │ 
https://oss.sonatype.org/content/repositories/snapshots/       │ no          
│ yes (daily) │ PID
+ops4j.sonatype.snapshots.deploy │ 
https://oss.sonatype.org/content/repositories/ops4j-snapshots/ │ no          
│ yes (daily) │ PID
+special                         │ https://repository.everfree.forest/        
                    │ yes (daily) │ no          │ SETTINGS
+
+== Default repositories
+ID                      │ URL                                                
      │ Releases    │ Snapshots
+────────────────────────┼──────────────────────────────────────────────────────────┼─────────────┼────────────
+system.repository       │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/system/   │ yes (daily) │ 
yes (daily)
+kar.repository          │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/kar/ │ yes (daily) │ 
yes (daily)
+child.system.repository │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/system/   │ yes (daily) │ 
yes (daily)</code></pre>
+</div>
+</div>
+<div class="ulist">
+<ul>
+<li>
+<p><code>-v</code> option shows additional information about policies related 
to given repository</p>
+</li>
+<li>
+<p><code>-x</code> shows credentials for given repository (if defined)</p>
+</li>
+</ul>
+</div>
+</div>
+<div class="sect4">
+<h5 id="_maven_password">maven:password</h5>
+<div class="paragraph">
+<p><code>org.ops4j.pax.url.mvn</code> bundle uses Aether library to handle 
Maven resolution. It uses <code>settings.xml</code> file if
+credentials have to be used when accessing remote Maven repositories. This 
isn&#8217;t done by <code>org.ops4j.pax.url.mvn</code>,
+but by Aether itself (or rather maven-settings library). When dealing with 
<code>settings.xml</code> file, passwords that
+are stored there may need to be decrypted.
+Outside of Karaf, we can use <code>mvn -emp</code> and <code>mvn -ep</code> 
passwords and manually configure <code>~/.m2/settings-security.xml</code>
+file.</p>
+</div>
+<div class="paragraph">
+<p>Karaf makes the task of managing credentials easier.</p>
+</div>
+<div class="paragraph">
+<p>In order to use encrypted repository (or http proxy) passwords inside 
<code>settings.xml</code> file, Maven must know the <em>master
+password</em> stored inside <code>settings-security.xml</code> file. This file 
isn&#8217;t usually present inside <code>~/.m2</code> directory and if
+there&#8217;s a need to use it, one has to be created manually.</p>
+</div>
+<div class="paragraph">
+<p>Here&#8217;s the way to encrypt Maven <em>master password</em> (which is 
used to encrypt ordinary passwords for repository or http proxies):</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; maven:password 
-emp
+Master password to encrypt: *****
+Encrypted master password: 
{y+p9TiYuwVEHMHV14ej0Ni34zBnXXQrIOqjww/3Ro6U=}</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>The above usage simply prints encrypted <em>master password</em>. We can 
however make this password persistent. This will
+result in new <code>settings-security.xml</code> file to be created and change 
in <code>org.ops4j.pax.url.mvn.security</code> property.</p>
+</div>
+<div class="admonitionblock note">
+<table>
+<tr>
+<td class="icon">
+<div class="title">Note</div>
+</td>
+<td class="content">
+Karaf maven commands will never overwrite your current 
<code>~/.m2/settings.xml</code> or <code>~/.m2/settings-security.xml</code> 
files.
+If there&#8217;s a need to change these files, maven commands will make a copy 
of existing file and set relevant <code>org.ops4j.pax.url.mvn</code> PID options
+to point to new locations.
+</td>
+</tr>
+</table>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; maven:password 
-emp --persist
+Maven security settings will be stored in new file. This file will be used in 
org.ops4j.pax.url.mvn.security property. Continue? (y/N) y
+Master password to encrypt: *****
+Encrypted master password: {lPPIFSUcPrMHnhwdauttAJYZcOe1D9sYGj4rwoaTwnY=}
+New security settings stored in 
"/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-security-settings-1498120766139.xml"
+karaf@root()&gt; maven:summary -x
+
+Option                    │ Value
+──────────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────────
+...
+Security settings file    │ 
/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-security-settings-1498120766139.xml
+Master password           │ admin
+...</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>Now, when Maven <em>master password</em> is set, we can encrypt ordinary 
passwords that may be then used when defining/changing
+remote repositories or http proxies:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; maven:password -ep
+Password to encrypt: *****
+Encrypted password: {fHl8U3pINkEH7RR1CufRT+utj5gJHfqsRgd6wTo92Eo=}
+You can use this encrypted password when defining repositories and 
proxies</code></pre>
+</div>
+</div>
+</div>
+<div class="sect4">
+<h5 id="_configuring_repositories_default_and_remote">Configuring repositories 
(default and remote)</h5>
+<div class="paragraph">
+<p>As mentioned before, there are two kinds of repositories that are 
used/queried by <code>org.ops4j.pax.url.mvn</code> bundle when resolving
+<code>mvn:</code> based URIs:</p>
+</div>
+<div class="dlist">
+<dl>
+<dt class="hdlist1">default repositories</dt>
+<dd>
+<p>These are read-only local repositories that are simply queried before 
performing any remote access.
+The best example of such repository is <code>$KARAF_HOME/system</code> 
directory.</p>
+</dd>
+<dt class="hdlist1">remote repositories</dt>
+<dd>
+<p>These are well-known Maven remote repositories - usually accessible over 
http(s) protocol. Popular
+repositories are Sonatype Nexus or JFrog Artifactory.</p>
+</dd>
+</dl>
+</div>
+<div class="paragraph">
+<p>Both kinds of repositories may be created using 
<code>maven:repository-add</code> command.</p>
+</div>
+<div class="paragraph">
+<p>Here&#8217;s how default repository may be created:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; 
maven:repository-add --default -id my.default.repository --snapshots 
'${karaf.home}/special-repository'
+
+...
+== Default repositories
+ID                      │ URL                                                
                │ Releases    │ Snapshots
+────────────────────────┼────────────────────────────────────────────────────────────────────┼─────────────┼────────────
+...
+my.default.repository   │ 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/special-repository/ │ yes 
(daily) │ yes (daily)</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>For remote repository, we can specify more options (like credentials or 
update policies):</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; 
maven:repository-add -idx 0 -id my.remote.repository --snapshots -up never 
--username admin --password '{fHl8U3pINkEH7RR1CufRT+utj5gJHfqsRgd6wTo92Eo=}' 
http://localhost/cloud-repository
+Maven settings will be updated and org.ops4j.pax.url.mvn.settings property 
will change. Continue? (y/N) y
+New settings stored in 
"/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-settings-1498121385253.xml"
+
+karaf@root()&gt; maven:repository-list -x
+
+== Remote repositories
+ID                              │ URL                                        
                    │ Username │ Password
+────────────────────────────────┼────────────────────────────────────────────────────────────────┼──────────┼─────────
+my.remote.repository            │ http://localhost/cloud-repository/         
                    │ admin    │ admin
+...</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>In the above example, new <code>settings.xml</code> file was created. The 
reason is that although new repository itself was added
+to <code>org.ops4j.pax.url.mvn.repositories</code> property, the credentials 
had to be stored in <code>settings.xml</code> file:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>&lt;servers&gt;
+  &lt;server&gt;
+    &lt;username&gt;admin&lt;/username&gt;
+    
&lt;password&gt;{fHl8U3pINkEH7RR1CufRT+utj5gJHfqsRgd6wTo92Eo=}&lt;/password&gt;
+    &lt;id&gt;my.remote.repository&lt;/id&gt;
+  &lt;/server&gt;
+&lt;/servers&gt;</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>Here&#8217;s summary of all options for <code>maven:repository-add</code> 
command:</p>
+</div>
+<div class="ulist">
+<ul>
+<li>
+<p><code>-id</code> mandatory identifier of repository</p>
+</li>
+<li>
+<p><code>-d</code> option may be used to configure default repositories 
instead of remote ones</p>
+</li>
+<li>
+<p><code>-nr</code> option disables non-SNAPSHOT artifacts resolution in this 
repository</p>
+</li>
+<li>
+<p><code>-s</code> option enables SNAPSHOT artifacts resolution in this 
repository</p>
+</li>
+<li>
+<p><code>-up</code> sets <em>update policy</em> for given repository 
(<code>daily</code>, <code>always</code>, <code>never</code>, 
<code>interval:MINUTES</code>)</p>
+</li>
+<li>
+<p><code>-cp</code> sets <em>checksum policy</em> for given repository 
(<code>fail</code>, <code>warn</code>, <code>ignore</code>)</p>
+</li>
+<li>
+<p><code>-f</code> disables confirmation prompts for commands</p>
+</li>
+<li>
+<p><code>-idx</code> allows to insert a repository at given position (instead 
of simply appending new repository at the end of current list of 
repositories)</p>
+</li>
+<li>
+<p><code>-u</code> sets username for remote repository access</p>
+</li>
+<li>
+<p><code>-p</code> sets password for remote repository access (may be 
encrypted using <code>maven:password -ep</code>)</p>
+</li>
+</ul>
+</div>
+<div class="paragraph">
+<p>After creating a repository, it may be deleted (using 
<code>maven:repository-remove</code> command) or changed 
(<code>maven:repository-change</code> command).
+All the options are the same as in <code>maven:repository-add</code> command. 
When removing a repository, only <code>-id</code> (and possibly 
<code>-d</code>) options are needed.</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; repository-remove 
-d -id my.default.repository
+Are you sure to remove repository with ID "my.default.repository" for URL 
file:/data/servers/apache-karaf-4.2.0-SNAPSHOT/special-repository/? (y/N) y
+
+karaf@root()&gt; repository-change -id special --username discord --password 
d1sc0rd
+Maven settings will be updated and org.ops4j.pax.url.mvn.settings property 
will change. Continue? (y/N) y
+New settings stored in 
"/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-settings-1498122026388.xml"</code></pre>
+</div>
+</div>
+</div>
+<div class="sect4">
+<h5 id="_configuring_http_proxies">Configuring HTTP proxies</h5>
+<div class="paragraph">
+<p>When accessing remote repositories using <code>org.ops4j.pax.url.mvn</code> 
(Aether library) there may be a need to let Maven/Aether
+know about HTTP proxies to use. HTTP proxies <strong>can&#8217;t be 
configured</strong> inside <code>etc/org.ops4j.pax.url.mvn.cfg</code> file. It 
has to
+be done in <code>settings.xml</code> and its location has to be set in 
<code>org.ops4j.pax.url.mvn.settings</code> PID property.</p>
+</div>
+<div class="paragraph">
+<p><code>maven:http-proxy</code> command can be used to add/change/remove HTTP 
proxy definition. It automatically does a copy
+of existing <code>settings.xml</code> file and changes 
<code>org.ops4j.pax.url.mvn.settings</code> PID property.</p>
+</div>
+<div class="paragraph">
+<p>For example:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>karaf@root()&gt; 
maven:http-proxy-list -x
+
+ID       │ Host                  │ Port │ Non-proxy hosts │ Username 
│ Password
+─────────┼───────────────────────┼──────┼─────────────────┼──────────┼─────────────
+my.proxy │ proxy.everfree.forest │ 3128 │ 192.168.2.*     │ admin    
│ super-secret
+
+karaf@root()&gt; maven:http-proxy --remove -id my.proxy
+New settings stored in 
"/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-settings-1498122255098.xml"
+
+No HTTP proxies configured in 
/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-settings-1498122255098.xml
+
+karaf@root()&gt; maven:http-proxy --add -id my.proxy --username discord 
--password '{fHl8U3pINkEH7RR1CufRT+utj5gJHfqsRgd6wTo92Eo=}' --non-proxy-hosts 
'127.*|192.168.*|localhost' proxy.everfree.forest:3128
+New settings stored in 
"/data/servers/apache-karaf-4.2.0-SNAPSHOT/data/cache/bundle53/data/maven-settings-1498122328731.xml"
+
+karaf@root()&gt; maven:http-proxy-list -x
+
+ID       │ Host                  │ Port │ Non-proxy hosts           │ 
Username │ Password
+─────────┼───────────────────────┼──────┼───────────────────────────┼──────────┼─────────
+my.proxy │ proxy.everfree.forest │ 3128 │ 127.*|192.168.*|localhost │ 
discord  │ admin</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>Here&#8217;s summary of options for <code>maven:http-proxy</code> 
command:</p>
+</div>
+<div class="ulist">
+<ul>
+<li>
+<p><code>-id</code> identifier of HTTP proxy</p>
+</li>
+<li>
+<p><code>-add</code> / <code>--change</code> / <code>--remove</code> is an 
operation to perform on proxy</p>
+</li>
+<li>
+<p><code>-f</code> disables confirmation prompts for commands</p>
+</li>
+<li>
+<p><code>-u</code> sets username for remote HTTP proxy</p>
+</li>
+<li>
+<p><code>-p</code> sets password for remote HTTP proxy (may be encrypted using 
<code>maven:password -ep</code>)</p>
+</li>
+<li>
+<p><code>-n</code> sets <em>non proxy hosts</em> option, which is 
<code>|</code>-separated list of glob patterns for IP addresses/host names that 
should be
+accessed bypassing HTTP proxy</p>
+</li>
+</ul>
+</div>
+<div class="paragraph">
+<p><code>maven:http-proxy</code> configures for example this section in 
<code>settings.xml</code>:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight nowrap"><code>&lt;proxies&gt;
+  &lt;proxy&gt;
+    &lt;username&gt;discord&lt;/username&gt;
+    
&lt;password&gt;{fHl8U3pINkEH7RR1CufRT+utj5gJHfqsRgd6wTo92Eo=}&lt;/password&gt;
+    &lt;port&gt;3128&lt;/port&gt;
+    &lt;host&gt;proxy.everfree.forest&lt;/host&gt;
+    &lt;nonProxyHosts&gt;127.*|192.168.*|localhost&lt;/nonProxyHosts&gt;
+    &lt;id&gt;my.proxy&lt;/id&gt;
+  &lt;/proxy&gt;
+&lt;/proxies&gt;</code></pre>
+</div>
+</div>
+</div>
+</div>
 </div>
 </div>
 <div id="footer">
 <div id="footer-text">
-Last updated 2016-04-27 13:59:28 CEST
+Last updated 2017-11-22 15:12:31 +01:00
 </div>
 </div>
 </body>

Modified: karaf/site/production/manual/latest/webconsole.html
URL: 
http://svn.apache.org/viewvc/karaf/site/production/manual/latest/webconsole.html?rev=1816059&r1=1816058&r2=1816059&view=diff
==============================================================================
--- karaf/site/production/manual/latest/webconsole.html (original)
+++ karaf/site/production/manual/latest/webconsole.html Wed Nov 22 14:52:25 2017
@@ -599,7 +599,7 @@ Right now, the WebConsole doesn&#8217;t
 </div>
 <div id="footer">
 <div id="footer-text">
-Last updated 2016-04-27 13:59:28 CEST
+Last updated 2017-07-26 16:36:29 +02:00
 </div>
 </div>
 </body>

Modified: karaf/site/production/manual/latest/webcontainer.html
URL: 
http://svn.apache.org/viewvc/karaf/site/production/manual/latest/webcontainer.html?rev=1816059&r1=1816058&r2=1816059&view=diff
==============================================================================
--- karaf/site/production/manual/latest/webcontainer.html (original)
+++ karaf/site/production/manual/latest/webcontainer.html Wed Nov 22 14:52:25 
2017
@@ -569,10 +569,56 @@ table.CodeRay td.code>pre{padding:0}
 <div class="sect4">
 <h5 id="_configuration">Configuration</h5>
 <div class="paragraph">
-<p>The default port used by the WebContainer is 8181.</p>
+<p>The default port used by the WebContainer is 8181. Note: the connector is 
actually bound only when at least a servlet or webapplication is using it.
+It means that just installing the <code>http</code> or <code>war</code> 
feature doesn&#8217;t bind the connector.</p>
 </div>
 <div class="paragraph">
-<p>The WebContainer configuration is in the <code>etc/jetty.xml</code> 
configuration file.</p>
+<p>By default, Karaf creates an internal Jetty connector that you can 
configure via <code>etc/org.ops4j.pax.web.cfg</code>:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay 
highlight"><code>org.osgi.service.http.port=8181</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>Note: if you want to use port numbers &lt; 1024, remember you have to run 
with root privileges.</p>
+</div>
+<div class="paragraph">
+<p>It&#8217;s possible to enable HTTPs "internal" connector. The first step is 
to create a keystore containing a server certificate.
+For instance the following command creates a keystore with a self-signed 
certificate:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight"><code>keytool -genkey -keyalg RSA -alias 
selfsigned -keystore keystore -storepass karaf1234 -validity 360 -keysize 
2048</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>Now, we can enable and configure the HTTPs connector with this keystore in 
<code>etc/org.ops4j.pax.web.cfg</code>:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay highlight"><code>org.osgi.service.http.port.secure=8443
+org.osgi.service.http.secure.enabled=true
+org.ops4j.pax.web.ssl.keystore=/path/to/keystore
+org.ops4j.pax.web.ssl.password=foo
+org.ops4j.pax.web.ssl.keypassword=karaf1234</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>It&#8217;s possible to use only HTTPs and to disable the HTTP using:</p>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay 
highlight"><code>org.osgi.service.http.enabled=false</code></pre>
+</div>
+</div>
+<div class="listingblock">
+<div class="content">
+<pre class="CodeRay 
highlight"><code>org.osgi.service.https.enabled=true</code></pre>
+</div>
+</div>
+<div class="paragraph">
+<p>As an alternative to the default connectors, it is possible to configure 
additional connectors in the <code>etc/jetty.xml</code> configuration file.</p>
 </div>
 <div class="paragraph">
 <p>The <code>etc/jetty.xml</code> is a standard Eclipse Jetty configuration 
file.</p>
@@ -940,7 +986,7 @@ corresponding to the bundle ID (as displ
 </div>
 <div id="footer">
 <div id="footer-text">
-Last updated 2016-04-27 13:59:28 CEST
+Last updated 2017-08-09 13:23:59 +02:00
 </div>
 </div>
 </body>

Modified: karaf/site/production/manual/latest/writing-tests.html
URL: 
http://svn.apache.org/viewvc/karaf/site/production/manual/latest/writing-tests.html?rev=1816059&r1=1816058&r2=1816059&view=diff
==============================================================================
--- karaf/site/production/manual/latest/writing-tests.html (original)
+++ karaf/site/production/manual/latest/writing-tests.html Wed Nov 22 14:52:25 
2017
@@ -947,7 +947,7 @@ The advantage though is that you can als
 </div>
 <div id="footer">
 <div id="footer-text">
-Last updated 2016-04-27 13:59:28 CEST
+Last updated 2017-07-26 16:36:29 +02:00
 </div>
 </div>
 </body>


Reply via email to