Skip to content

Commit

Permalink
docker-compost.test.yml 4
Browse files Browse the repository at this point in the history
  • Loading branch information
rdzman committed Jun 5, 2024
1 parent a553220 commit 0e5938a
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,8 @@ WORKDIR /tmp
FROM base AS matpower_local
ONBUILD ARG MP_SRC
ONBUILD ARG BRANCH
# ONBUILD COPY docker/matpower_docker_tests/matpower_docker_tests_8.sh /usr/local/bin/matpower_docker_tests.sh
ONBUILD COPY ./docker/matpower_docker_tests/matpower_docker_tests_8.sh /usr/local/bin/matpower_docker_tests.sh
ONBUILD COPY . $HOME/packages/matpower
ONBUILD RUN ls -al $HOME/packages/matpower
ONBUILD RUN git clone -b ${BRANCH} --depth=1 https://github.com/MATPOWER/matpower-extras.git $HOME/packages/matpower/extras && \
rm -rf $HOME/packages/matpower/extras/.git && \
octave-cli --no-gui -p $HOME/packages/matpower --eval "install_matpower(1,1,1)"
Expand All @@ -47,7 +46,7 @@ ONBUILD RUN git clone -b ${BRANCH} --depth=1 https://github.com/MATPOWER/matpowe
FROM base AS matpower_github
ONBUILD ARG MP_SRC
ONBUILD ARG BRANCH
ONBUILD COPY docker/matpower_docker_tests/matpower_docker_tests_8.sh /usr/local/bin/matpower_docker_tests.sh
ONBUILD COPY ./docker/matpower_docker_tests/matpower_docker_tests_8.sh /usr/local/bin/matpower_docker_tests.sh
ONBUILD RUN git clone -b ${BRANCH} --depth=1 https://github.com/MATPOWER/matpower.git $HOME/packages/matpower && \
git clone -b ${BRANCH} --depth=1 https://github.com/MATPOWER/matpower-extras.git $HOME/packages/matpower/extras && \
rm -rf $HOME/packages/matpower/.git && \
Expand All @@ -57,16 +56,16 @@ ONBUILD RUN git clone -b ${BRANCH} --depth=1 https://github.com/MATPOWER/matpowe
# Select source for MATPOWER files
FROM matpower_${MP_SRC} AS matpower

# # conditionally disable a warning in .octaverc (for Octave 6.x+ and MATPOWER 7.0)
# FROM matpower AS warn_0
# FROM matpower AS warn_1
# ONBUILD RUN echo "warning('off', 'Octave:empty-index');" >> $HOME/.octaverc
# FROM warn_${WARN} as warn
#
# FROM warn AS patch_0
# FROM warn AS patch_1
# ONBUILD COPY docker/patches/t_most_mpopf.patch $HOME/packages/
# ONBUILD RUN patch -u -b $HOME/packages/matpower/most/lib/t/t_most_mpopf.m -i $HOME/packages/t_most_mpopf.patch
# FROM patch_${PATCH_MOST_TEST}
# conditionally disable a warning in .octaverc (for Octave 6.x+ and MATPOWER 7.0)
FROM matpower AS warn_0
FROM matpower AS warn_1
ONBUILD RUN echo "warning('off', 'Octave:empty-index');" >> $HOME/.octaverc
FROM warn_${WARN} as warn

FROM warn AS patch_0
FROM warn AS patch_1
ONBUILD COPY ./docker/patches/t_most_mpopf.patch $HOME/packages/
ONBUILD RUN patch -u -b $HOME/packages/matpower/most/lib/t/t_most_mpopf.m -i $HOME/packages/t_most_mpopf.patch
FROM patch_${PATCH_MOST_TEST}

WORKDIR "${HOME}"

0 comments on commit 0e5938a

Please sign in to comment.