wiki/howto/windestimation.md
... ...
@@ -17,7 +17,7 @@ To complete the training process successfully, you need to make sure that you ha
17 17
18 18
### Docker-Based
19 19
20
-In our docker registry under ``docker.sapsailing.com:443`` there is a repository called ``windestimationtraining`` where images can be found to run the training process in a mostly automated way. All you need is an account for ``docker.sapsailing.com:443`` and an account on ``sapsailing.com`` that has the ``TRACKED_RACE:EXPORT`` permission for all races in the archive server (see the ``raw-data`` role). Furthermore, you need a MongoDB with approximately 100GB of available space. This can be a MongoDB replica set, of course. All you need is the URI to establish the connection.
20
+In our docker registry under ``docker.sapsailing.com`` there is a repository called ``windestimationtraining`` where images can be found to run the training process in a mostly automated way. All you need is an account for ``docker.sapsailing.com`` and an account on ``sapsailing.com`` that has the ``TRACKED_RACE:EXPORT`` permission for all races in the archive server (see the ``raw-data`` role). Furthermore, you need a MongoDB with approximately 100GB of available space. This can be a MongoDB replica set, of course. All you need is the URI to establish the connection.
21 21
22 22
If you want to try the following on a plain Amazon Linux instance, try to start with an instance type that has fast SSD storage attached (NVMe) and 16GB of RAM, such as ``c5d.2xlarge``. SSH into it (probably with the ``ec2-user`` account), then try this:
23 23
... ...
@@ -26,13 +26,14 @@ If you want to try the following on a plain Amazon Linux instance, try to start
26 26
# Launch cfdisk for the NVMe volume, give it a gpt partition table and create a single partition spanning the entire disk:
27 27
cfdisk /dev/nvme1n1
28 28
mkfs.xfs /dev/nvme1n1p1
29
+ mkdir /var/lib/mongo
29 30
mount /dev/nvme1n1p1 /var/lib/mongo
30 31
echo "[mongodb-org-4.4]
31 32
name=MongoDB Repository
32 33
baseurl=https://repo.mongodb.org/yum/amazon/2013.03/mongodb-org/4.4/x86_64/
33 34
gpgcheck=1
34 35
enabled=1
35
-gpgkey=https://www.mongodb.org/static/pgp/server-4.4.asc" >/etc/yum.repos.d
36
+gpgkey=https://www.mongodb.org/static/pgp/server-4.4.asc" >/etc/yum.repos.d/mongodb-org-4.4.repo
36 37
yum update
37 38
yum install -y mongodb-org-server mongodb-org-tools mongodb-org-shell docker
38 39
chown mongod /var/lib/mongo
... ...
@@ -52,14 +53,16 @@ storage:
52 53
net:
53 54
port: 27017
54 55
- bindIp: 127.0.0.1
55
-+ bindIp: 172.17.0.1,127.0.0.1
56
++ bindIp: "172.17.0.1,127.0.0.1"
56 57
```
57 58
58 59
Then continue as follows:
59 60
60 61
```
62
+ systemctl start docker.service
61 63
systemctl start mongod
62 64
systemctl start docker
65
+ docker login docker.sapsailing.com
63 66
touch /tmp/windEstimationModels.dat
64 67
```
65 68
... ...
@@ -71,7 +74,7 @@ For your account that is equipped with the ``TRACKED_RACE:EXPORT`` permission yo
71 74
-e MONGODB_URI="mongodb://172.17.0.1/windestimation?retryWrites=true" \
72 75
-e BEARER_TOKEN="{your-bearer-token-here}" \
73 76
-e MEMORY=-Xmx8g \
74
- docker.sapsailing.com:443/windestimationtraining:latest
77
+ docker.sapsailing.com/windestimationtraining:latest
75 78
```
76 79
If successful (and you may want to remove the ``--rm`` option otherwise to allow you to inspect logs after unsuccessful execution) you will find the output under ``/tmp/windEstimationModels.dat`` which you can upload as usual, e.g., as in
77 80
```
... ...
@@ -85,7 +88,7 @@ If successful (and you may want to remove the ``--rm`` option otherwise to allow
85 88
Under ``docker/Dockerfile_windestimation`` there is a docker file that can be used to produce the Docker image, given that a ``WindEstimationModelsTraining.jar`` exists under [https://static.sapsailing.com/WindEstimationModelsTraining.jar](https://static.sapsailing.com/WindEstimationModelsTraining.jar). Producing an image works like this:
86 89
87 90
```
88
- docker build --no-cache -f Dockerfile_windestimation -t docker.sapsailing.com:443/windestimationtraining:0.0.4 .
91
+ docker build --no-cache -f Dockerfile_windestimation -t docker.sapsailing.com/windestimationtraining:0.0.4 .
89 92
```
90 93
91 94
To produce the JAR file used for the Docker image creation, run an "Export" command in Eclipse, using "File - Export - Runnable JAR File" with the ``SimpleModelsTrainingPart1`` launch configuration. This will export a JAR that you can then upload to ``trac@sapsailing.com:static`` using a command such as