diff --git a/.travis.yml b/.travis.yml index b89fdd8f5..2ae932c61 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,6 +10,7 @@ jobs: allow_failures: - name: "Ubuntu 18.04.sudo.mpich [Job failure permitted]" - name: "Ubuntu 16.04 home PETSc [Job failure permitted]" + - name: "[16.04 PETSc] OpenFOAM <-> CalculiX [FSI] [Job failure permitted]" include: - stage: Building preCICE @@ -360,7 +361,7 @@ jobs: all_branches: true script: python push.py -s -t of-of_np - - name: "[16.04 PETSc] OpenFOAM <-> CalculiX [FSI]" + - name: "[16.04 PETSc] OpenFOAM <-> CalculiX [FSI] [Job failure permitted]" script: - python system_testing.py -s of-ccx_fsi --base Ubuntu1604.home.PETSc after_failure: diff --git a/compare_results.sh b/compare_results.sh index a200baee3..5f237bd43 100644 --- a/compare_results.sh +++ b/compare_results.sh @@ -32,7 +32,7 @@ do case $i in max_diff_limit="${i#*=}" ;; *) - echo "Uknown options $i. Possible options: --avg_diff, --max_diff "; exit 1;; + echo "Unknown options $i. Possible options: --avg_diff, --max_diff "; exit 1;; esac done diff --git a/silent_compose.sh b/silent_compose.sh index a1edb4ce9..7e6a5888a 100644 --- a/silent_compose.sh +++ b/silent_compose.sh @@ -1,45 +1,49 @@ #!/bin/bash -# Runs docker-compose in the detached mode silently and then displays logs for the failed +# Runs docker-compose in the detached mode silently and then displays logs for the failed # services as well as ones, that could not finish communication in the timeout time taillen=500 failed=0 -docker-compose up -d || exit 1 -services=($(docker-compose ps | awk '{print $1}'| tail -n +3)) +if [ "$1" = "debug" ]; then + docker-compose up +else + docker-compose up -d || exit 1 + services=($(docker-compose ps | awk '{print $1}'| tail -n +3)) -# maximum test timeout is 10 minutes -for i in {1..10}; do - for service in ${services[@]}; do - # check if the service is still running - if [ -z "$(docker ps | grep $service | cut -d ' ' -f 1)" ]; then - if [ "$(docker inspect $service --format='{{.State.ExitCode}}')" -eq 1 ]; then - echo "$service failed! Find the logs below" - failed=1 - docker-compose logs --tail=$taillen $service - fi - # pop - services=(${services[@]/$service}) - fi - done - # exit if nothing is running - if [ ${#services[@]} -eq 0 ]; then - echo "All adapters finished!" - exit $failed - fi - echo "Running the simulation...Be patient" - sleep 60 -done + # maximum test timeout is 10 minutes + for i in {1..10}; do + for service in ${services[@]}; do + # check if the service is still running + if [ -z "$(docker ps | grep $service | cut -d ' ' -f 1)" ]; then + if [ "$(docker inspect $service --format='{{.State.ExitCode}}')" -eq 1 ]; then + echo "$service failed! Find the logs below" + failed=1 + docker-compose logs --tail=$taillen $service + fi + # pop + services=(${services[@]/$service}) + fi + done + # exit if nothing is running + if [ ${#services[@]} -eq 0 ]; then + echo "All adapters finished!" + exit $failed + fi + echo "Running the simulation...Be patient" + sleep 60 + done -echo "Timeout!" -echo "Printing logs for services:" + echo "Timeout!" + echo "Printing logs for services:" -# probably failed due to communication issues, -# list individual logs and exit -for service in ${services[@]}; do - docker-compose logs --tail=$taillen $service - docker-compose stop $service -done + # probably failed due to communication issues, + # list individual logs and exit + for service in ${services[@]}; do + docker-compose logs --tail=$taillen $service + docker-compose stop $service + done -exit 1 + exit 1 +fi diff --git a/system_testing.py b/system_testing.py index 554c10a1a..3cbc5ff17 100644 --- a/system_testing.py +++ b/system_testing.py @@ -44,7 +44,7 @@ def build_adapters(systest, tag, branch, local, force_rebuild): docker_args = { 'tag': '', 'build_args': {"from": docker.get_namespace() + baseimage_name if local else 'precice/' + baseimage_name }, - 'force_rebuild': force_rebuild, + 'force_rebuild': force_rebuild, 'dockerfile': 'Dockerfile'} with common.chdir(os.path.join(os.getcwd(), 'adapters')): @@ -57,7 +57,7 @@ def build_adapters(systest, tag, branch, local, force_rebuild): if os.path.exists("Dockerfile.{}".format(participant)): docker.build_image(**docker_args) -def run_compose(systest, branch, local, tag, force_rebuild, rm_all): +def run_compose(systest, branch, local, tag, force_rebuild, rm_all=False, verbose=False): """ Runs necessary systemtest with docker compose """ test_dirname = "TestCompose_{systest}".format(systest = systest) @@ -67,12 +67,17 @@ def run_compose(systest, branch, local, tag, force_rebuild, rm_all): # set up environment variables, to detect precice base image, that we # should run with and docker images location - commands_main = ["""export PRECICE_BASE=-{base}; {extra_cmd} docker-compose config && - bash ../../silent_compose.sh""".format(base = - adapter_base_name, extra_cmd =\ - "export SYSTEST_REMOTE={remote};".format( - remote = docker.get_namespace()) if local else "" ), - "docker cp tutorial-data:/Output ."] + export_cmd = "export PRECICE_BASE=-{}; ".format(adapter_base_name) + extra_cmd = "export SYSTEST_REMOTE={}; ".format(docker.get_namespace()) if local else "" + compose_config_cmd = "docker-compose config && " + compose_exec_cmd = "bash ../../silent_compose.sh {}".format('debug' if verbose else "") + copy_cmd = "docker cp tutorial-data:/Output ." + + commands_main = [export_cmd + + extra_cmd + + compose_config_cmd + + compose_exec_cmd, + copy_cmd] # rebuild tutorials image if needed if force_rebuild: commands_main.insert(0, "docker-compose build --no-cache") @@ -84,8 +89,8 @@ def run_compose(systest, branch, local, tag, force_rebuild, rm_all): # cleanup previous results shutil.rmtree("Output", ignore_errors=True) - - try: + + try: for command in commands_main: ccall(command) @@ -98,7 +103,7 @@ def run_compose(systest, branch, local, tag, force_rebuild, rm_all): for command in commands_cleanup: ccall(command) - except (CalledProcessError, IncorrectOutput) as e: + except (CalledProcessError, IncorrectOutput) as e: # cleanup in either case if rm_all: for command in commands_cleanup: @@ -141,10 +146,15 @@ def comparison(pathToRef, pathToOutput): num_diff = call("bash ../../compare_results.sh {} {}".format(pathToRef, pathToOutput)) if num_diff == 1: raise IncorrectOutput(*ret) + elif num_diff != 0: + raise ValueError('compare_results.sh exited with unknown code {}'.format(num_diff)) + else: + print('Test succeeded! Differences to referenceOutput within tolerance.') + else: + print('Test succeeded! No difference to referenceOutput found.') - -def build_run_compare(test, tag, branch, local_precice, force_rebuild, rm_all): +def build_run_compare(test, tag, branch, local_precice, force_rebuild, rm_all=False, verbose=False): """ Runs and compares test, using precice branch. """ compose_tests = ["dealii-of", "of-of", "su2-ccx", "of-ccx", "of-of_np", "fe-fe","nutils-of", "of-ccx_fsi"] @@ -152,7 +162,7 @@ def build_run_compare(test, tag, branch, local_precice, force_rebuild, rm_all): if local_precice: build_adapters(test_basename, tag, branch, local_precice, force_rebuild) if test_basename in compose_tests: - run_compose(test, branch, local_precice, tag, force_rebuild, rm_all) + run_compose(test, branch, local_precice, tag, force_rebuild, rm_all, verbose) else: # remaining, non-compose tests test_dirname = "Test_{systest}".format(systest=test) @@ -171,14 +181,15 @@ def build_run_compare(test, tag, branch, local_precice, force_rebuild, rm_all): if __name__ == "__main__": # Parsing flags parser = argparse.ArgumentParser(description='Build local.') - parser.add_argument('-l', '--local', action='store_true', help="use local preCICE image (default: use remote image)") - parser.add_argument('-s', '--systemtest', type=str, help="choose system tests you want to use", + parser.add_argument('-l', '--local', action='store_true', help="Use local preCICE image (default: use remote image)") + parser.add_argument('-s', '--systemtest', type=str, help="Choose system tests you want to use", choices = common.get_tests(), required = True) parser.add_argument('-b', '--branch', help="preCICE branch to use", default = "develop") parser.add_argument('-f', '--force_rebuild', nargs='+', help="Force rebuild of variable parts of docker image", default = [], choices = ["precice", "tests"]) parser.add_argument('--base', type=str,help="Base preCICE image to use", default= "Ubuntu1604.home") + parser.add_argument('-v', '--verbose', action='store_true',help="Verbose output of participant containers") args = parser.parse_args() # check if there is specialized dir for this version test_name = args.systemtest @@ -190,4 +201,4 @@ def build_run_compare(test, tag, branch, local_precice, force_rebuild, rm_all): test = test[0] tag = args.base.lower() build_run_compare(test, tag, args.branch.lower(), args.local, - args.force_rebuild, False) + args.force_rebuild, rm_all=False, verbose=args.verbose) diff --git a/tests/TestCompose_dealii-of/Dockerfile.tutorial_data b/tests/TestCompose_dealii-of/Dockerfile.tutorial_data index 6fef56401..a36285ffc 100644 --- a/tests/TestCompose_dealii-of/Dockerfile.tutorial_data +++ b/tests/TestCompose_dealii-of/Dockerfile.tutorial_data @@ -4,10 +4,11 @@ RUN apk add git ARG branch=develop RUN git clone --branch $branch https://github.com/precice/tutorials -RUN mkdir configs && sed -e 's|gather-scatter"|gather-scatter" exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g' $tutorial_path/precice-config_serial.xml > configs/precice-config.xml +RUN mkdir configs && sed -e 's|||g'\ + $tutorial_path/precice-config.xml > configs/precice-config.xml RUN sed -i '/application pimpleFoam/d; s/\/\/ application pimpleDyMFoam/application pimpleDyMFoam/g' \ $tutorial_path/Fluid/system/controlDict -RUN rm $tutorial_path/precice-config_serial.xml $tutorial_path/precice-config.xml +RUN rm $tutorial_path/precice-config.xml RUN rm -rfv $tutorial_path/Fluid/0/ RUN cp -r $tutorial_path/Fluid/0.orig/ $tutorial_path/Fluid/0/ RUN addgroup -g 1000 precice && adduser -u 1000 -G precice -D precice && chown -R precice:precice tutorials configs diff --git a/tests/TestCompose_dealii-of/docker-compose.yml b/tests/TestCompose_dealii-of/docker-compose.yml index 173d62d6a..666ad208f 100644 --- a/tests/TestCompose_dealii-of/docker-compose.yml +++ b/tests/TestCompose_dealii-of/docker-compose.yml @@ -1,9 +1,9 @@ version : '3' services: - - dealii-adapter: + + dealii-adapter: image: "${SYSTEST_REMOTE}dealii-adapter${PRECICE_BASE}:${DEALII_TAG}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ @@ -12,16 +12,16 @@ services: - output:/home/precice/Data/Output/ command: > /bin/bash -c " - ln -sf configs/* . && + ln -sf configs/* . && ./coupled_elasto_dynamics /home/precice/Data/Input/parameters.prm" container_name: dealii-adapter depends_on: - tutorial-data - openfoam-adapter - - openfoam-adapter: + + openfoam-adapter: image: "${SYSTEST_REMOTE}openfoam-adapter${PRECICE_BASE}:${OPENFOAM_TAG}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ @@ -29,7 +29,7 @@ services: - configs:/home/precice/openfoam-adapter/configs/ - output:/home/precice/Data/Output/ command: > - /bin/bash -c "source /opt/openfoam4/etc/bashrc && + /bin/bash -c "source /opt/openfoam4/etc/bashrc && ln -sf configs/* . && blockMesh -case /home/precice/Data/Input && checkMesh -case /home/precice/Data/Input && diff --git a/tests/TestCompose_fe-fe.Ubuntu1804.home/Dockerfile.tutorial_data b/tests/TestCompose_fe-fe.Ubuntu1804.home/Dockerfile.tutorial_data index bccc42289..51ff17d00 100644 --- a/tests/TestCompose_fe-fe.Ubuntu1804.home/Dockerfile.tutorial_data +++ b/tests/TestCompose_fe-fe.Ubuntu1804.home/Dockerfile.tutorial_data @@ -3,7 +3,7 @@ ENV tutorial_path tutorials/HT/partitioned-heat/fenics-fenics RUN apk add git ARG branch=develop RUN git clone --branch $branch https://github.com/precice/tutorials -RUN mkdir configs && sed -i 's|network="lo"|exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g' $tutorial_path/precice-config.xml +RUN mkdir configs && sed -i 's|||g' $tutorial_path/precice-config.xml RUN addgroup -g 1000 precice && adduser -u 1000 -G precice -D precice && chown -R precice:precice tutorials configs USER precice diff --git a/tests/TestCompose_nutils-of.Ubuntu1804/Dockerfile.tutorial_data b/tests/TestCompose_nutils-of.Ubuntu1804/Dockerfile.tutorial_data index 3115281dc..7d945a453 100644 --- a/tests/TestCompose_nutils-of.Ubuntu1804/Dockerfile.tutorial_data +++ b/tests/TestCompose_nutils-of.Ubuntu1804/Dockerfile.tutorial_data @@ -8,10 +8,9 @@ RUN git clone --branch $branch https://github.com/precice/tutorials WORKDIR / # adjust configuration and paths RUN mkdir configs && cp $tutorial_path/precice-config.xml configs/precice-config.xml && \ - sed -i 's|exchange-directory\=".."|exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g' \ + sed -i 's|exchange-directory="\.\."|exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g' \ configs/precice-config.xml && \ - sed -i 's|\.\./precice-config.xml|configs/precice-config.xml|g' $tutorial_path/Nutils/cht.py && \ - sed -i 's|\.\./precice-config.xml|configs/precice-config.xml|g' $tutorial_path/OpenFOAM/precice-adapter-config.yml - + sed -i 's|\.\./precice-config\.xml|configs/precice-config.xml|g' $tutorial_path/Nutils/cht.py && \ + sed -i 's|\.\./precice-config\.xml|configs/precice-config.xml|g' $tutorial_path/OpenFOAM/precice-adapter-config.yml RUN addgroup -g 1000 precice && adduser -u 1000 -G precice -D precice && chown -R precice:precice tutorials configs USER precice diff --git a/tests/TestCompose_nutils-of.Ubuntu1804/docker-compose.yml b/tests/TestCompose_nutils-of.Ubuntu1804/docker-compose.yml index 7b1d1b164..55642a5a9 100644 --- a/tests/TestCompose_nutils-of.Ubuntu1804/docker-compose.yml +++ b/tests/TestCompose_nutils-of.Ubuntu1804/docker-compose.yml @@ -1,9 +1,8 @@ version: '3' services: - openfoam-adapter-outer: image: "${SYSTEST_REMOTE}openfoam-adapter${PRECICE_BASE}:${OPENFOAM_TAG}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ @@ -11,10 +10,10 @@ services: - openfoam_input:/home/precice/Data/Input/ - configs:/home/precice/openfoam-adapter/configs/ command: > - /bin/bash -c "source /opt/openfoam5/etc/bashrc + /bin/bash -c "sleep 10 && source /opt/openfoam5/etc/bashrc && blockMesh -case /home/precice/Data/Input && buoyantPimpleFoam -case /home/precice/Data/Input - && cp -r /home/precice/Data/Input/. /home/precice/Data/Output/OpenFOAM" + && cp -r /home/precice/Data/Input/. /home/precice/Data/Output/OpenFOAM" container_name: openfoam-adapter-outer depends_on: - tutorial-data @@ -26,7 +25,7 @@ services: dockerfile: Dockerfile.nutils args: from: "${SYSTEST_REMOTE}precice${PRECICE_BASE}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ @@ -35,7 +34,7 @@ services: - configs:/home/precice/nutils/configs/ command: > /bin/bash -c "ln -sf /home/precice/Data/Input/* . - && python3 cht.py + && python3 cht.py && mkdir /home/precice/Data/Output/Nutils && cp *.log *.vtk /home/precice/Data/Output/Nutils" container_name: nutils-adapter depends_on: @@ -45,7 +44,10 @@ services: build: context: . dockerfile: Dockerfile.tutorial_data + args: + branch: "develop" volumes: + - exchange:/Exchange/ - openfoam_input:/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-nutils/OpenFOAM - nutils_input:/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-nutils/Nutils - configs:/configs/ diff --git a/tests/TestCompose_of-ccx/Dockerfile.tutorial_data b/tests/TestCompose_of-ccx/Dockerfile.tutorial_data index 1f62b916a..810029160 100644 --- a/tests/TestCompose_of-ccx/Dockerfile.tutorial_data +++ b/tests/TestCompose_of-ccx/Dockerfile.tutorial_data @@ -8,7 +8,7 @@ RUN git clone --branch $branch https://github.com/precice/tutorials # Copy modified configs COPY controlDict $tutorial_path/Inner-Fluid/system/controlDict COPY controlDict $tutorial_path/Outer-Fluid/system/controlDict -COPY precice-config_serial.xml configs/precice-config.xml +COPY precice-config.xml configs/precice-config.xml # Download meshes WORKDIR $tutorial_path diff --git a/tests/TestCompose_of-ccx/precice-config.xml b/tests/TestCompose_of-ccx/precice-config.xml new file mode 100644 index 000000000..f4b126834 --- /dev/null +++ b/tests/TestCompose_of-ccx/precice-config.xml @@ -0,0 +1,92 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/TestCompose_of-ccx/precice-config_serial.xml b/tests/TestCompose_of-ccx/precice-config_serial.xml deleted file mode 100644 index 040ed90ab..000000000 --- a/tests/TestCompose_of-ccx/precice-config_serial.xml +++ /dev/null @@ -1,92 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tests/TestCompose_of-ccx_fsi.Ubuntu1604.home.PETSc/Dockerfile.tutorial_data b/tests/TestCompose_of-ccx_fsi.Ubuntu1604.home.PETSc/Dockerfile.tutorial_data index f61fa543b..b0a875863 100644 --- a/tests/TestCompose_of-ccx_fsi.Ubuntu1604.home.PETSc/Dockerfile.tutorial_data +++ b/tests/TestCompose_of-ccx_fsi.Ubuntu1604.home.PETSc/Dockerfile.tutorial_data @@ -13,9 +13,9 @@ RUN sed -i '/application pimpleFoam/d; s/\/\/ application pimpleDyMFoam/ $tutorial_path/Fluid/system/controlDict RUN mkdir configs && \ - sed 's|distribution-type="gather-scatter"|distribution-type="gather-scatter" exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g' \ - $tutorial_path/precice-config_serial.xml > configs/precice-config.xml && cp $tutorial_path/config.yml configs/ -RUN rm $tutorial_path/precice-config_serial.xml $tutorial_path/precice-config.xml + sed -e 's||g' \ + $tutorial_path/precice-config.xml > configs/precice-config.xml && cp $tutorial_path/config.yml configs/ +RUN rm $tutorial_path/precice-config.xml RUN addgroup -g 1000 precice && adduser -u 1000 -G precice -D precice && chown -R precice:precice tutorials configs USER precice diff --git a/tests/TestCompose_of-of/docker-compose.yml b/tests/TestCompose_of-of/docker-compose.yml index 3d3a8bc25..90aeedb4d 100644 --- a/tests/TestCompose_of-of/docker-compose.yml +++ b/tests/TestCompose_of-of/docker-compose.yml @@ -10,7 +10,7 @@ services: command: > /bin/bash -c "source /opt/openfoam4/etc/bashrc && cd /home/precice/openfoam-adapter/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-laplacianFoam && - sed -i 's|gather-scatter\"|gather-scatter\" exchange-directory=\"/home/precice/Data/Exchange/\" network=\"eth0\"|g' precice-config_serial.xml && + sed -i 's|||g' precice-config.xml && ./runFluid && cp -r Fluid/ /home/precice/Data/Output/" container_name: openfoam-adapter-fluid @@ -25,7 +25,7 @@ services: command: > /bin/bash -c "source /opt/openfoam4/etc/bashrc && cd /home/precice/openfoam-adapter/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-laplacianFoam && - sed -i 's|gather-scatter\"|gather-scatter\" exchange-directory=\"/home/precice/Data/Exchange/\" network=\"eth0\"|g' precice-config_serial.xml && + sed -i 's|||g' precice-config.xml && ./runSolid && cp -r Solid/ /home/precice/Data/Output/" container_name: openfoam-adapter-solid diff --git a/tests/TestCompose_of-of_np/docker-compose.yml b/tests/TestCompose_of-of_np/docker-compose.yml index 6d7ca8cc6..8fade523b 100644 --- a/tests/TestCompose_of-of_np/docker-compose.yml +++ b/tests/TestCompose_of-of_np/docker-compose.yml @@ -10,7 +10,7 @@ services: command: > /bin/bash -c "source /opt/openfoam4/etc/bashrc && cd /home/precice/openfoam-adapter/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-laplacianFoam_nearest-projection && - sed -i 's|gather-scatter\"|gather-scatter\" exchange-directory=\"/home/precice/Data/Exchange/\" network=\"eth0\"|g' precice-config_serial.xml && + sed -i 's|||g' precice-config.xml && ./runFluid && cp -r Fluid/ /home/precice/Data/Output/" container_name: openfoam-adapter-fluid @@ -25,7 +25,7 @@ services: command: > /bin/bash -c "source /opt/openfoam4/etc/bashrc && cd /home/precice/openfoam-adapter/tutorials/CHT/flow-over-plate/buoyantPimpleFoam-laplacianFoam_nearest-projection && - sed -i 's|gather-scatter\"|gather-scatter\" exchange-directory=\"/home/precice/Data/Exchange/\" network=\"eth0\"|g' precice-config_serial.xml && + sed -i 's|||g' precice-config.xml && ./runSolid && cp -r Solid/ /home/precice/Data/Output/" container_name: openfoam-adapter-solid diff --git a/tests/TestCompose_su2-ccx/Dockerfile.tutorial_data b/tests/TestCompose_su2-ccx/Dockerfile.tutorial_data index ece776d60..001e336ae 100644 --- a/tests/TestCompose_su2-ccx/Dockerfile.tutorial_data +++ b/tests/TestCompose_su2-ccx/Dockerfile.tutorial_data @@ -4,9 +4,9 @@ RUN apk add git bash ARG branch=develop RUN git clone --branch $branch https://github.com/precice/tutorials -RUN mkdir configs && sed -e 's|exchange-directory="../"|exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g'\ - $tutorial_path/precice-config_serial.xml > configs/precice-config.xml -RUN rm $tutorial_path/precice-config_serial.xml $tutorial_path/precice-config.xml +RUN mkdir configs && sed -e 's|exchange-directory="../"|exchange-directory="/home/precice/Data/Exchange/" network="eth0"|g'\ + $tutorial_path/precice-config.xml > configs/precice-config.xml +RUN rm $tutorial_path/precice-config.xml RUN cp $tutorial_path/config.yml configs/ RUN addgroup -g 1000 precice && adduser -u 1000 -G precice -D precice && chown -R precice:precice tutorials configs USER precice diff --git a/tests/TestCompose_su2-ccx/docker-compose.yml b/tests/TestCompose_su2-ccx/docker-compose.yml index 93684264e..5f18b5d95 100644 --- a/tests/TestCompose_su2-ccx/docker-compose.yml +++ b/tests/TestCompose_su2-ccx/docker-compose.yml @@ -1,8 +1,8 @@ version : '3' services: - calculix-adapter: + calculix-adapter: image: "${SYSTEST_REMOTE}calculix-adapter${PRECICE_BASE}:${CALCULIX_TAG}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ @@ -10,7 +10,7 @@ services: - input_solid:/home/precice/Data/Input/ - configs:/home/precice/calculix-adapter/configs command: > - /bin/bash -c "ln -sf /home/precice/Data/Input Solid; + /bin/bash -c "ln -sf /home/precice/Data/Input Solid; ln -sf /home/precice/calculix-adapter/configs/* . && ccx_preCICE -i Solid/flap -precice-participant Calculix && cp Solid/*.dat Solid/*.cvg Solid/*.sta *.log *.out /home/precice/Data/Output/" @@ -20,20 +20,20 @@ services: su2-adapter: image: "${SYSTEST_REMOTE}su2-adapter${PRECICE_BASE}:${SU2_TAG}" - networks: + networks: - precicecomm volumes: - exchange:/home/precice/Data/Exchange/ - output:/home/precice/Data/Output/ - input_fluid:/home/precice/Data/Input/ - configs:/home/precice/su2-adapter/configs - command: > - /bin/bash -c "ln -sf /home/precice/Data/Input Fluid && + command: > + /bin/bash -c "ln -sf /home/precice/Data/Input Fluid && ln -sf /home/precice/su2-adapter/configs/* . && SU2_CFD Fluid/euler_config_coupled.cfg && cp flow*.vtk *.csv *.dat *SU2*.log /home/precice/Data/Output/" container_name: su2-adapter - depends_on: + depends_on: - tutorial-data tutorial-data: @@ -45,7 +45,7 @@ services: - input_fluid:/tutorials/FSI/flap_perp/SU2-CalculiX/Fluid - configs:/configs/ - output:/Output/ - container_name: tutorial-data + container_name: tutorial-data networks: precicecomm: