Skip to content

Commit fb71f23

Browse files
committed
Prepare Dockerfile for snapshot version 6.0-alpha1
1 parent b20db8a commit fb71f23

File tree

7 files changed

+16
-14
lines changed

7 files changed

+16
-14
lines changed

Dockerfile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ FROM debian:jessie-backports
22

33
MAINTAINER Miguel Moquillon "miguel.moquillon@silverpeas.org"
44

5-
ARG SILVERPEAS_VERSION=6.0-SNAPSHOT
5+
ARG SILVERPEAS_VERSION=6.0-alpha1
66
ARG WILDFLY_VERSION=10.0.0
77
ARG DEFAULT_LOCALE=en_US.UTF-8
88

@@ -105,19 +105,19 @@ RUN wget -nc https://www.silverpeas.org/files/silverpeas-${SILVERPEAS_VERSION}-w
105105

106106
# Copy the Maven settings.xml required to install Silverpeas by fetching the software bundles from
107107
# the Silverpeas Nexus Repository
108-
COPY settings.xml ${HOME}/.m2/
108+
COPY src/settings.xml ${HOME}/.m2/
109109

110110
# Copy the database configuration parameters from which the global configuration config.properties
111111
# will be generated
112-
COPY db_config.properties ${SILVERPEAS_HOME}/configuration/
112+
COPY src/db_config.properties ${SILVERPEAS_HOME}/configuration/
113113
RUN cp ${SILVERPEAS_HOME}/configuration/db_config.properties ${SILVERPEAS_HOME}/configuration/config.properties
114114

115115
# Set the default working directory
116116
WORKDIR ${SILVERPEAS_HOME}/bin
117117

118118
# Copy this container init script that will be run each time the container is ran
119-
COPY run.sh /opt/
120-
COPY ooserver /opt/
119+
COPY src/run.sh /opt/
120+
COPY src/ooserver /opt/
121121

122122
# Assemble the Silverpeas application with its working directories and marks it as ready to complete
123123
# the installation of Silverpeas in Wildfly at first run

README.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22

33
A Dockerfile that produces a standalone Docker image of [Silverpeas 6][silverpeas] for testing purpose.
44
In this image, H2 is embedded and used as the default database for Silverpeas. No dependencies on other containers are required for its running.
5+
6+
Ready-to-use docker images of Silverpeas for testing purpose are available in our [Docker Hub repository][dockerhub]
7+
58
[silverpeas]: http://www.silverpeas.org
9+
[dockerhub]: https://hub.docker.com/r/silverpeas/silverpeas-test/
610

711
## Image creation
812

@@ -16,22 +20,20 @@ Otherwise, to create an image of a given version of Silverpeas 6, you have to sp
1620
```
1721
$ ./build.sh 6.0 10.0.0
1822
```
19-
This will build an image containing Silverpeas 6.0 (not yet available) and Wildfly 10.0.0 with the tag `silverpeas-test-6.0`. The versions passed as argument have to match the versions of Silverpeas and Wildfly available in the Web; indeed, Silverpeas and Wildfly will be downloaded from their respective project Web site.
23+
This will build an image containing Silverpeas 6.0 (not yet available) and Wildfly 10.0.0 with the tag `silverpeas/silverpeas-test-6.0`. The versions passed as argument have to match the versions of Silverpeas and Wildfly available in the Web; indeed, Silverpeas and Wildfly will be downloaded from their respective project Web site.
2024

2125
## Container running
2226

23-
[data-volume]: https://docs.docker.com/engine/userguide/containers/dockervolumes/
24-
2527
To run a container `silverpeas-test` from an image, just do:
2628
```
27-
$ docker run --name silverpeas-test -p 8080:8000 -d silverpeas-test
29+
$ docker run --name silverpeas-test -p 8080:8000 -d silverpeas/silverpeas-test
2830
```
2931
The image exposes the 8000 port at which Silverpeas listens, and this port of the container is mapped to the 8080 port of the host.
3032

3133
When the container is instanciated from the image, a configuration step is performed before starting Silverpeas.
3234
If you have no custom configurations to apply before running Silverpeas, you can avoid this step by starting directly Silverpeas:
3335
```
34-
$ docker run --name silverpeas-test -p 8080:8000 -d silverpeas-test start
36+
$ docker run --name silverpeas-test -p 8080:8000 -d silverpeas/silverpeas-test start
3537
```
3638

3739
### Keep data out of the container
@@ -45,7 +47,7 @@ $ docker run --name silverpeas-test -p 8080:8000 -d \
4547
-v /home/me/silverpeas/log:/opt/silverpeas/log \
4648
-v /home/me/silverpeas/data:/opt/silverpeas/data \
4749
-v /home/me/silverpeas/h2:/opt/silverpeas/h2 \
48-
silverpeas-test
50+
silverpeas/silverpeas-test
4951
```
5052

5153
### Custom configuration
@@ -65,7 +67,7 @@ mount it to the container:
6567
```
6668
$ docker run --name silverpeas-test -p 8080:8000 -d \
6769
-v /home/me/silverpeas/custom_config.properties:/opt/silverpeas/configuration/custom_config.properties \
68-
silverpeas-test
70+
silverpeas/silverpeas-test
6971
```
7072
(Warning: don't shift the configuration step if you want the `custom_config.properties` to be taken into account.)
7173

build.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ if [ $# -eq 2 ]; then
77
docker build \
88
--build-arg SILVERPEAS_VERSION=$silverpeas_version \
99
--build-arg WILDFLY_VERSION=$wildfly_version \
10-
-t silverpeas-test:$silverpeas_version \
10+
-t silverpeas/silverpeas-test:$silverpeas_version \
1111
.
1212
else
1313
docker build \
14-
-t silverpeas-test:latest \
14+
-t silverpeas/silverpeas-test:latest \
1515
.
1616
fi
File renamed without changes.

ooserver renamed to src/ooserver

File renamed without changes.

run.sh renamed to src/run.sh

File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)