Skip to content

Commit

Permalink
[KARAF-6600] Use https URL for Maven Central
Browse files Browse the repository at this point in the history
  • Loading branch information
jbonofre committed Jan 16, 2020
1 parent 7dd2063 commit c29efdf
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ org.ops4j.pax.url.mvn.certificateCheck=true

#
# Default this to false. It's just weird to use undocumented repos
# "false" means that http://repo1.maven.org/maven2@id=central won't be
# "false" means that https://repo1.maven.org/maven2@id=central won't be
# implicitly used as remote repository
#
org.ops4j.pax.url.mvn.useFallbackRepositories=false
Expand Down Expand Up @@ -101,9 +101,8 @@ org.ops4j.pax.url.mvn.defaultRepositories=\
# profiles defined in effective settings.xml file will be _appended_ to this
# list
# The default list includes the following repositories:
# http://repo1.maven.org/maven2@id=central
# http://repository.apache.org/content/groups/snapshots-group@id=apache@snapshots@noreleases
# https://oss.sonatype.org/content/repositories/snapshots@id=sonatype.snapshots.deploy@snapshots@noreleases
# https://repo1.maven.org/maven2@id=central
# https://repository.apache.org/content/groups/snapshots-group@id=apache@snapshots@noreleases
# https://oss.sonatype.org/content/repositories/ops4j-snapshots@id=ops4j.sonatype.snapshots.deploy@snapshots@noreleases
# A repository url can be appended with zero or more of the following flags:
# @snapshots : the repository contains snapshots
Expand All @@ -112,8 +111,8 @@ org.ops4j.pax.url.mvn.defaultRepositories=\
# settings.xml this is optional but recommended
#
org.ops4j.pax.url.mvn.repositories= \
http://repo1.maven.org/maven2@id=central, \
http://repository.apache.org/content/groups/snapshots-group@id=apache@snapshots@noreleases, \
https://repo1.maven.org/maven2@id=central, \
https://repository.apache.org/content/groups/snapshots-group@id=apache@snapshots@noreleases, \
https://oss.sonatype.org/content/repositories/ops4j-snapshots@id=ops4j.sonatype.snapshots.deploy@snapshots@noreleases

#
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ library.jolokia-agent=mvn\:org.jolokia/jolokia-jvm/1.2.2/jar/agent

org.ops4j.pax.url.mvn.repositories= \
file:${runtime.home}/${karaf.default.repository}@snapshots@id=karaf-default, \
http://repo1.maven.org/maven2@id=central
https://repo1.maven.org/maven2@id=central


4 changes: 2 additions & 2 deletions itests/test/src/test/resources/etc/org.ops4j.pax.url.mvn.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ org.ops4j.pax.url.mvn.localRepository=${karaf.data}/repository

#
# Default this to false. It's just weird to use undocumented repos
# "false" means that http://repo1.maven.org/maven2@id=central won't be
# "false" means that https://repo1.maven.org/maven2@id=central won't be
# implicitly used as remote repository
#
org.ops4j.pax.url.mvn.useFallbackRepositories=false
Expand Down Expand Up @@ -108,7 +108,7 @@ org.ops4j.pax.url.mvn.defaultRepositories=\
# settings.xml this is optional but recommended
#
org.ops4j.pax.url.mvn.repositories= \
http://repo1.maven.org/maven2@id=central
https://repo1.maven.org/maven2@id=central

#
# Global policies override repository-specific settings (@checksum=..., @update=..., @releasesUpdate=..., ...)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public void karExtractTest() throws Exception {
File base = new File("target/test");
base.mkdirs();

Kar kar = new Kar(new URI("http://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.2.2/framework-4.2.2.kar"));
Kar kar = new Kar(new URI("https://repo1.maven.org/maven2/org/apache/karaf/features/framework/4.2.2/framework-4.2.2.kar"));
File repoDir = new File("target/test/framework-repo");
repoDir.mkdirs();
File resourcesDir = new File("target/test/framework-resources");
Expand Down
10 changes: 5 additions & 5 deletions manual/src/main/asciidoc/user-guide/urls.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The main information provided by a feature is the set of OSGi bundles that defin

[source,options="nowrap"]
----
<bundle>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</bundle>
<bundle>https://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</bundle>
----

Doing this will make sure the above bundle is installed while installing the feature.
Expand Down Expand Up @@ -94,8 +94,8 @@ Require Config Admin │ true
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
Remote repositories │ https://repo1.maven.org/maven2/ │ PID configuration
https://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
Expand All @@ -122,8 +122,8 @@ karaf@root()> 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
central │ https://repo1.maven.org/maven2/ │ yes (daily) │ no │ PID
apache │ https://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
Expand Down

0 comments on commit c29efdf

Please sign in to comment.