FLARE-forecast / FLARE-containers

Docker containers to run FLARE forecast
0 stars 2 forks source link

Check file download complition for flare-download-noaa #22

Open vahid-dan opened 3 years ago

vahid-dan commented 3 years ago

In flare-download-noaa the part to check if the file is downloaded completely is removed due to an issue occurs while running in OpenWhisk mode. It was adding the following lines to the logs repeatedly and filling up the disk space until it crashes the container:

web_1  | +(/home/user/flare/flare-container.sh:164): read -r line
web_1  | +(/home/user/flare/flare-container.sh:166): [[ [7][7][0], 290.09998 = \l\o\n\,\ \[\1\] ]]

The following lines are removed from flare-container.sh:

    # COMPLETED_CHECK=false

    # Check if file is completed.
    # while IFS= read -r line
    # do
    #   if [[ $line = "lon, [1]" ]];then
    #     COMPLETED_CHECK=true
    #   fi
    # done < "$FILE"
    # if [[ "${COMPLETED_CHECK}" = false ]];then
    #   info "${FILE} is not completed."
    #   break
vahid-dan commented 3 years ago

@Yun-Jung Check the commented lines in the description of the issue. You need to uncomment most of them in order to make your changes work. Currently, it does nothing if the file is not completed.

Yun-Jung commented 3 years ago

@vahid-dan Done!