@@ -14,12 +14,65 @@ Vocabularies and format changes are managed on [Argo Vocabs Task Team - AVTT Git
1414- source code
1515
1616## Run Argo NetCDF file format checker
17- - Using file_checker_exec-[ version] .jar :
17+ ### Using file_checker_exec-{ version} .jar :
1818``` bash
19- java -jar file_checker_exec-[ version] .jar $OPTION $DAC_NAME $SPEC $OUTPUT_DIR $INPUT_DIR $FILE_NAME
19+ java -jar file_checker_exec-{ version} .jar $OPTION $DAC_NAME $SPEC $OUTPUT_DIR $INPUT_DIR [ $FILES_NAMES ]
2020```
21+ $FILES_NAMES is a list of file's name from the INPUT_DIR. It is optional : without it, all files from INPUT_DIR will be checked.
2122
22- Only this JAR file is needed. You can delete legacy log4j2 & netcdf libraries jar files.
23+ ### Run the application using Docker
24+
25+ ``` bash
26+ docker run --rm -v [ABSOLUTE_PATH_TO_SPEC]:/app/file_checker_spec -v [ABSOLUTE_PATH_TO_DATA_FOLDER]:/app/data -v [ABSOLUTE_PATH_TO_OUTPUT_DIR]:/app/results ghcr.io/oneargo/argoformatchecker/app:{TAG} $DAC_NAME ./file_checker_spec ./results ./data [$FILES_NAMES ]
27+ ```
28+ You need to mount external directories to the container :
29+
30+ [ ABSOLUTE_PATH_TO_SPEC] : the file_checker_spec directory path.
31+
32+ [ ABSOLUTE_PATH_TO_DATA_FOLDER] : Path to directory containing the argo necdf files to be checked. The fileChecker will not seek files in subfolders
33+
34+ [ ABSOLUTE_PATH_TO_OUTPUT_DIR] : the directory where xml results files * .filecheck will be created
35+
36+ Example :
37+ ``` bash
38+ docker run --rm -v D:\t est_file_checker\f ile_checker_spec:/app/file_checker_spec -v D:\t est_file_checker\d atatest:/app/data -v D:\t est_file_checker\r esults:/app/results ghcr.io/oneargo/argoformatchecker/app:develop -no-name-check coriolis ./file_checker_spec ./results ./data
39+ ```
40+
41+ ### Run the application using Docker Compose
42+ To facilitate the use of Argo file checker a compose.yaml and .env files are provided :
43+
44+ - Prepare your data.
45+ - Copy ` .env.docs ` as ` .env ` file, and customize variables to configure the file checker for your environment.
46+ - Download compose.yaml
47+ - Run te service using Docker Compose:
48+ ``` bash
49+ docker compose -f compose.yaml up
50+ ```
51+ or in background :
52+
53+ ``` bash
54+ docker compose -f compose.yaml up -d
55+ ```
56+ Example of an .env file :
57+ ```
58+ # file checker image
59+ FILECHECKER_IMAGE=ghcr.io/oneargo/argoformatchecker/app
60+ FILECHECKER_IMAGE_TAG=develop
61+
62+ # External directories to mount to the container
63+ FILECHECKER_SPEC_VOLUME='D:\test_compose\file_checker_spec'
64+ FILECHECKER_INPUT_VOLUME='D:\test_compose\data'
65+ FILECHECKER_OUTPUT_VOLUME='D:\test_compose\results'
66+
67+ # Variable specific to floats to check
68+ DAC_NAME=bodc
69+ FILECHECKER_OPTIONS=
70+ FILES_NAMES=
71+
72+ ```
73+ ### Test data :
74+ To test the Argo File Checker, you will find argo data here : https://www.argodatamgt.org/DataAccess.html
75+ The Argo File Checker is not yet designed to checking * prof.nc and * Sprof.nc. It checks only TRAJ, META, TECH and PROFILES files.
2376
2477## TOOLS
2578
@@ -48,7 +101,7 @@ cd file_checker_exec
48101In target folder you will find both original-file_checker_exec and file_checker_exec-[ version] . It is this last one to use.
49102
50103
51- ### Using docker
104+ ### build docker image
52105
53106
54107- Build the application with Docker :
@@ -57,11 +110,6 @@ In target folder you will find both original-file_checker_exec and file_checker_
57110docker build -t filechecker_2.8.14 .
58111```
59112
60- - Run the application using Docker
61-
62- ```
63- docker run --rm -v [ABSOLUTE_PATH_TO_file_checker_spec]:/app/file_checker_spec -v [ABSOLUTE_PATH_TO_DATA_FOLDER]:/app/data -v [ABSOLUTE_PATH_TO_OUTPUT_DIR]:/app/results filechecker_2.8.14:latest $DAC_NAME ./file_checker_spec ./results ./data $FILE_NAME
64- ```
65113
66114### Run integration tests
67115The source code comes with some netcdf test files. You can run the integration tests with this following command :
0 commit comments