summary refs log tree commit diff
diff options
context:
space:
mode:
authorDavid Robertson <davidr@element.io>2022-10-12 10:47:02 +0100
committerGitHub <noreply@github.com>2022-10-12 10:47:02 +0100
commit3f057e4c54ff1e4ef8b4f651c35d4698b389fe9b (patch)
treea70e7d5a9a7b49ccc25edd6b1066ee30d4636b03
parentFix a bug where redactions were not being sent over federation if we did not ... (diff)
downloadsynapse-3f057e4c54ff1e4ef8b4f651c35d4698b389fe9b.tar.xz
Use minimal Rust installation in docker images and CI (#14141)
-rw-r--r--changelog.d/14141.docker1
-rw-r--r--changelog.d/14141.misc1
-rw-r--r--docker/Dockerfile2
-rw-r--r--docker/Dockerfile-dhvirtualenv2
-rw-r--r--pyproject.toml2
5 files changed, 5 insertions, 3 deletions
diff --git a/changelog.d/14141.docker b/changelog.d/14141.docker
new file mode 100644
index 0000000000..561806cdae
--- /dev/null
+++ b/changelog.d/14141.docker
@@ -0,0 +1 @@
+Use the `minimal` Rust profile when building Synapse.
diff --git a/changelog.d/14141.misc b/changelog.d/14141.misc
new file mode 100644
index 0000000000..561806cdae
--- /dev/null
+++ b/changelog.d/14141.misc
@@ -0,0 +1 @@
+Use the `minimal` Rust profile when building Synapse.
diff --git a/docker/Dockerfile b/docker/Dockerfile
index b20951d4cf..48fe95d9fd 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -106,7 +106,7 @@ ENV CARGO_HOME=/cargo
 ENV PATH=/cargo/bin:/rust/bin:$PATH
 RUN mkdir /rust /cargo
 
-RUN curl -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain stable
+RUN curl -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain stable --profile minimal
 
 # To speed up rebuilds, install all of the dependencies before we copy over
 # the whole synapse project, so that this layer in the Docker cache can be
diff --git a/docker/Dockerfile-dhvirtualenv b/docker/Dockerfile-dhvirtualenv
index ca3a259081..73165f6f85 100644
--- a/docker/Dockerfile-dhvirtualenv
+++ b/docker/Dockerfile-dhvirtualenv
@@ -92,7 +92,7 @@ ENV CARGO_HOME=/cargo
 ENV PATH=/cargo/bin:/rust/bin:$PATH
 RUN mkdir /rust /cargo
 
-RUN curl -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain stable
+RUN curl -sSf https://sh.rustup.rs | sh -s -- -y --no-modify-path --default-toolchain stable --profile minimal
 
 
 COPY --from=builder /dh-virtualenv_1.2.2-1_all.deb /
diff --git a/pyproject.toml b/pyproject.toml
index 5e36baf40d..3dc4b66ca9 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -316,7 +316,7 @@ build-backend = "poetry.core.masonry.api"
 skip = "cp36* *-musllinux_i686"
 
 # We need a rust compiler
-before-all =  "curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y"
+before-all =  "curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y --profile minimal"
 environment= { PATH = "$PATH:$HOME/.cargo/bin" }
 
 # For some reason if we don't manually clean the build directory we