Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
awlayton committed Feb 12, 2024
1 parent bd9b68d commit 11d27ce
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 15 deletions.
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.

ARG COMPOSE_VER=alpine-1.29.2
ARG OADA_VER=3.6.1
ARG DOCKER_VER=cli
ARG OADA_VER=3.10.0

# Fetch the oada compose file
FROM docker/compose:$COMPOSE_VER as oada-compose
FROM docker:$DOCKER_VER AS oada-compose
ARG OADA_VER

RUN if test "${OADA_VER}" = 'latest'; then \
Expand All @@ -25,7 +25,7 @@ RUN if test "${OADA_VER}" = 'latest'; then \
wget https://github.com/OADA/server/releases/download/v${OADA_VER}/docker-compose.yml; \
fi

FROM docker/compose:$COMPOSE_VER
FROM docker:$DOCKER_VER

WORKDIR /qlever-oada

Expand All @@ -42,7 +42,7 @@ RUN apk add --no-cache \
COPY ./entrypoint.sh /entrypoint.sh

ENTRYPOINT ["/usr/bin/dumb-init", "--rewrite", "15:2", "--", "/entrypoint.sh"]
CMD ["up"]
CMD ["up", "--no-log-prefix"]

# Wait for /bookmarks to be up
HEALTHCHECK --start-period=4m --interval=5s --retries=50 CMD \
Expand Down
5 changes: 3 additions & 2 deletions docker-compose.override.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@

# Create network for piping between the proxy and the "oada" container
networks:
pipe:
qlever_oada_pipe:
external: true

services:
startup:
Expand All @@ -30,7 +31,7 @@ services:
expose:
- "80"
networks:
pipe:
qlever_oada_pipe:
aliases:
- oada-dood
http_net:
Expand Down
14 changes: 6 additions & 8 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.

if test "$1" = 'up'; then
# Connect this container to the oada pipe
docker network create qlever-oada_pipe
docker network connect qlever-oada_pipe "$(hostname)"

# Forward this containers port 80 to OADA port 80
socat TCP-LISTEN:80,fork TCP:oada-dood:80 &
fi
# Connect this container to the oada pipe
docker network create qlever_oada_pipe
docker network connect qlever_oada_pipe "$(hostname)"

# Forward this containers port 80 to OADA port 80
socat TCP-LISTEN:80,fork TCP:oada-dood:80 &

docker-compose "$@"

0 comments on commit 11d27ce

Please sign in to comment.