Cannot build the docker image with error `base.sh: line 206: cd: /usr/lib/postgresql/17/bin`
Hi all, I tried to build the docker image from the master
Here is the docker image build log:
https://github.com/leungpeng/spilo/actions/runs/13319991067/job/37202679512
can conform this. happens to me as well. the build was fine a few days ago if i remember
demo mode also not building, output of docker build --tag spilo-test --build-arg DEMO=true --no-cache .:
=> [builder-false 11/14] COPY build_scripts/patroni_wale.sh build_scripts/compress_build.sh /builddeps/ 0.0s
=> ERROR [builder-false 12/14] RUN bash /builddeps/patroni_wale.sh 7.1s
------
> [builder-false 12/14] RUN bash /builddeps/patroni_wale.sh:
0.188 + BUILD_PACKAGES=(python3-pip python3-wheel python3-dev git patchutils binutils gcc)
0.188 + apt-get update
0.443 Get:1 http://apt.postgresql.org/pub/repos/apt jammy-pgdg InRelease [129 kB]
0.500 Get:2 http://security.ubuntu.com/ubuntu jammy-security InRelease [129 kB]
0.596 Get:3 http://archive.ubuntu.com/ubuntu jammy InRelease [270 kB]
0.698 Err:1 http://apt.postgresql.org/pub/repos/apt jammy-pgdg InRelease
0.698 The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 7FCC7D46ACCC4CF8
0.841 Get:4 http://security.ubuntu.com/ubuntu jammy-security/universe Sources [361 kB]
0.952 Get:5 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [1230 kB]
1.023 Get:6 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [2609 kB]
1.125 Get:7 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [128 kB]
1.179 Get:9 http://security.ubuntu.com/ubuntu jammy-security/restricted amd64 Packages [3612 kB]
1.295 Get:10 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [127 kB]
1.371 Get:11 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [45.2 kB]
1.457 Get:12 http://archive.ubuntu.com/ubuntu jammy/universe Sources [22.0 MB]
1.795 Get:8 https://packagecloud.io/timescale/timescaledb/ubuntu jammy InRelease [29.2 kB]
2.609 Get:13 https://packagecloud.io/timescale/timescaledb/ubuntu jammy/main amd64 Packages [162 kB]
3.149 Get:14 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [17.5 MB]
4.271 Get:15 http://archive.ubuntu.com/ubuntu jammy/main amd64 Packages [1792 kB]
4.585 Get:16 http://archive.ubuntu.com/ubuntu jammy/restricted amd64 Packages [164 kB]
4.614 Get:17 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [266 kB]
4.657 Get:18 http://archive.ubuntu.com/ubuntu jammy-updates/universe Sources [553 kB]
4.775 Get:19 http://archive.ubuntu.com/ubuntu jammy-updates/multiverse amd64 Packages [53.3 kB]
4.800 Get:20 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages [1526 kB]
5.121 Get:21 http://archive.ubuntu.com/ubuntu jammy-updates/restricted amd64 Packages [3748 kB]
5.718 Get:22 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [2911 kB]
6.125 Get:23 http://archive.ubuntu.com/ubuntu jammy-backports/main amd64 Packages [81.4 kB]
6.135 Get:24 http://archive.ubuntu.com/ubuntu jammy-backports/universe amd64 Packages [35.2 kB]
6.249 Reading package lists...
7.059 W: GPG error: http://apt.postgresql.org/pub/repos/apt jammy-pgdg InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 7FCC7D46ACCC4CF8
7.059 E: The repository 'http://apt.postgresql.org/pub/repos/apt jammy-pgdg InRelease' is not signed.
------
Dockerfile:79
--------------------
77 | WORKDIR /
78 |
79 | >>> RUN bash /builddeps/patroni_wale.sh
80 |
81 | RUN if [ "$COMPRESS" = "true" ]; then bash /builddeps/compress_build.sh; fi
--------------------
ERROR: failed to solve: process "/bin/sh -c bash /builddeps/patroni_wale.sh" did not complete successfully: exit code: 100
@seekermarcel hey! You can solve it by adding something like this to bypass gpgcheck:
RUN echo 'Acquire::AllowInsecureRepositories "true";' > /etc/apt/apt.conf.d/99insecure \ && echo 'APT::Get::AllowUnauthenticated "true";' >> /etc/apt/apt.conf.d/99insecure
Not the secure way, but stable workaround anyway.