Skip to content

Commit 0d4837a

Browse files
committed
Added oracle maven server config
1 parent d86079e commit 0d4837a

File tree

3 files changed

+71
-0
lines changed

3 files changed

+71
-0
lines changed

.travis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ cache:
2121
- $DOCKER_CFG
2222

2323
install:
24+
- bash .travis/maven_cfg.sh
2425
- bash .travis/start_db.sh
2526
- bash .travis/install_utplsql.sh
2627

.travis/maven_cfg.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
set -e
3+
cd $(dirname $(readlink -f $0))
4+
5+
if [ "$ORACLE_OTN_USER" == "" ] || [ "$ORACLE_OTN_PASSWORD" == "" ]; then
6+
echo "Oracle OTN username/password not specified."
7+
fi
8+
9+
MAVEN_SETTINGS=$HOME/.m2/settings.xml
10+
11+
# Copy the maven settings file to the right place, and set the username/password for oracle maven server.
12+
cp settings.tmpl.xml $MAVEN_SETTINGS
13+
sed -i -e "s|###USERNAME###|$ORACLE_OTN_USER|g" $MAVEN_SETTINGS
14+
sed -i -e "s|###PASSWORD###|$ORACLE_OTN_PASSWORD|g" $MAVEN_SETTINGS

.travis/settings.tmpl.xml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
3+
<!--
4+
Licensed to the Apache Software Foundation (ASF) under one
5+
or more contributor license agreements. See the NOTICE file
6+
distributed with this work for additional information
7+
regarding copyright ownership. The ASF licenses this file
8+
to you under the Apache License, Version 2.0 (the
9+
"License"); you may not use this file except in compliance
10+
with the License. You may obtain a copy of the License at
11+
12+
http://www.apache.org/licenses/LICENSE-2.0
13+
14+
Unless required by applicable law or agreed to in writing,
15+
software distributed under the License is distributed on an
16+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17+
KIND, either express or implied. See the License for the
18+
specific language governing permissions and limitations
19+
under the License.
20+
-->
21+
22+
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
23+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
24+
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
25+
26+
<servers>
27+
<server>
28+
<id>maven.oracle.com</id>
29+
<username>###USERNAME###</username>
30+
<password>###PASSWORD###</password>
31+
<configuration>
32+
<basicAuthScope>
33+
<host>ANY</host>
34+
<port>ANY</port>
35+
<realm>OAM 11g</realm>
36+
</basicAuthScope>
37+
<httpConfiguration>
38+
<all>
39+
<params>
40+
<property>
41+
<name>http.protocol.allow-circular-redirects</name>
42+
<value>%b,true</value>
43+
</property>
44+
</params>
45+
</all>
46+
</httpConfiguration>
47+
</configuration>
48+
</server>
49+
</servers>
50+
51+
<pluginGroups></pluginGroups>
52+
<proxies></proxies>
53+
<mirrors></mirrors>
54+
<profiles></profiles>
55+
56+
</settings>

0 commit comments

Comments
 (0)