Annotate

tools/build-env/Containerfile @ 13745:994ea8d54b72 13.0

core.configmanager: Pass name and line number in context Delays the string interpolation until the warning is logged, which may slightly lower memory usage. Allows retrieving the filename and line number easily.
author Kim Alvefur <zash@zash.se>
date Sat, 22 Feb 2025 00:04:51 +0100
parent 13323:7bfd6db52528
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
13323
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
1 ARG os
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
2 ARG dist
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
3 FROM ${os:-debian}:${dist:-sid}
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
4 ENV DEBIAN_FRONTEND noninteractive
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
5 RUN set -ex; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
6 apt-get update; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
7 apt-get install -y --no-install-recommends \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
8 ccache dh-lua libicu-dev libidn11-dev libssl-dev \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
9 lua-bitop lua-dbi-mysql lua-dbi-postgresql lua-dbi-sqlite3 \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
10 lua-event lua-expat lua-filesystem lua-ldap lua-sec lua-socket \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
11 luarocks shellcheck mercurial; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
12 apt-get install -y ca-certificates dns-root-data; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
13 apt-get install -y lua-bit32 || true; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
14 apt-get install -y lua-busted || true; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
15 apt-get install -y lua-check || true; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
16 apt-get install -y lua-readline || true; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
17 apt-get install -y lua-unbound || true; \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
18 update-alternatives --set lua-interpreter /usr/bin/lua5.4 || true \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
19 apt-get clean
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
20
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
21 # Place this file in an empty directory and build the image with
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
22 # podman build . -t prosody.im/build-env
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
23 #
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
24 # Substituting podman for docker should work, where that is what's available.
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
25 #
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
26 # Then in a source directory, run:
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
27 # podman run -it --rm -v "$PWD:$PWD" -w "$PWD" --entrypoint /bin/bash \
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
28 # --userns=keep-id --network host prosody.im/build-env
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
29 #
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
30 # In the resulting environment everything required to compile and run prosody
7bfd6db52528 tools/build-env: Tools for building and testing in a container
Kim Alvefur <zash@zash.se>
parents:
diff changeset
31 # is available, so e.g. `./configure; make; ./prosody` should Just Work!