From 5f89401a7cbd3368f9ffe5af628a4c456bf77744 Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Tue, 8 Dec 2020 20:06:21 +0900 Subject: [PATCH 1/2] Update Rust on buildenv image --- .circleci/images/plume-buildenv/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/images/plume-buildenv/Dockerfile b/.circleci/images/plume-buildenv/Dockerfile index 03259fcb..e1de78c7 100644 --- a/.circleci/images/plume-buildenv/Dockerfile +++ b/.circleci/images/plume-buildenv/Dockerfile @@ -8,7 +8,7 @@ RUN apt update &&\ rm -rf /var/lib/apt/lists/* #install and configure rust -RUN curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain nightly-2020-01-15 -y &&\ +RUN curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain nightly-2020-12-07 -y &&\ rustup component add rustfmt clippy &&\ rustup component add rust-std --target wasm32-unknown-unknown From 55abbff9b83038c02847fb1210a904dd1bc036f3 Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Tue, 8 Dec 2020 20:07:13 +0900 Subject: [PATCH 2/2] Use Caddy v2 on build env --- .circleci/images/plume-buildenv/Caddyfile | 7 ++----- .circleci/images/plume-buildenv/Dockerfile | 8 +++++--- script/run_browser_test.sh | 2 +- 3 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.circleci/images/plume-buildenv/Caddyfile b/.circleci/images/plume-buildenv/Caddyfile index cc7a4352..4b38f5ac 100644 --- a/.circleci/images/plume-buildenv/Caddyfile +++ b/.circleci/images/plume-buildenv/Caddyfile @@ -1,6 +1,3 @@ -localhost:443 { - proxy / localhost:7878 { - transparent - } - tls self_signed +localhost { + reverse_proxy localhost:7878 } diff --git a/.circleci/images/plume-buildenv/Dockerfile b/.circleci/images/plume-buildenv/Dockerfile index e1de78c7..e0de900a 100644 --- a/.circleci/images/plume-buildenv/Dockerfile +++ b/.circleci/images/plume-buildenv/Dockerfile @@ -4,7 +4,10 @@ ENV PATH="/root/.cargo/bin:${PATH}" #install native/circleci/build dependancies RUN apt update &&\ apt install -y --no-install-recommends git ssh tar gzip ca-certificates default-jre&&\ - apt install -y --no-install-recommends binutils-dev build-essential cmake curl gcc gettext git libcurl4-openssl-dev libdw-dev libelf-dev libiberty-dev libpq-dev libsqlite3-dev libssl-dev make openssl pkg-config postgresql postgresql-contrib python zlib1g-dev python3-pip zip unzip libclang-dev&&\ + echo "deb [trusted=yes] https://apt.fury.io/caddy/ /" \ + | tee -a /etc/apt/sources.list.d/caddy-fury.list &&\ + apt update &&\ + apt install -y --no-install-recommends binutils-dev build-essential cmake curl gcc gettext git libcurl4-openssl-dev libdw-dev libelf-dev libiberty-dev libpq-dev libsqlite3-dev libssl-dev make openssl pkg-config postgresql postgresql-contrib python zlib1g-dev python3-pip zip unzip libclang-dev clang caddy&&\ rm -rf /var/lib/apt/lists/* #install and configure rust @@ -24,8 +27,7 @@ COPY cargo_config /root/.cargo/config #install selenium for front end tests RUN pip3 install selenium -#install and configure caddy -RUN curl https://getcaddy.com | bash -s personal +#configure caddy COPY Caddyfile /Caddyfile #install crowdin diff --git a/script/run_browser_test.sh b/script/run_browser_test.sh index 8861b6b3..96294500 100755 --- a/script/run_browser_test.sh +++ b/script/run_browser_test.sh @@ -10,7 +10,7 @@ plm instance new -d plume-test.local -n plume-test plm users new -n admin -N 'Admin' -e 'email@exemple.com' -p 'password' plume & -caddy -conf /Caddyfile & +caddy run -config /Caddyfile & until curl http://localhost:7878/test/health -f; do sleep 1; done 2>/dev/null >/dev/null