Skip to content

Conversation

@zachhannum
Copy link
Contributor

@zachhannum zachhannum commented Jun 20, 2025

With rstudio/rstudio-pro#8394, we now build and package the session init entrypoint with the session components. This PR updates the session init docker file to use this new packaged binary as the entrypoint, but also build it as before for backwards compatibility (mainly for our current 2025.05 release that still needs to build from main).

This should alleviate or pretty much fully fix the platform support issues we had around our release vs. dev builds needing different versions of the init code.

I ran these locally to verify both paths:

Build with bundled binary
#0 building with "desktop-linux" instance using docker driver

#1 [internal] load build definition from Dockerfile.ubuntu2204
#1 transferring dockerfile: 2.59kB done
#1 DONE 0.0s

#2 [internal] load metadata for docker.io/library/ubuntu:22.04
#2 DONE 0.3s

#3 [internal] load .dockerignore
#3 transferring context: 2B done
#3 DONE 0.0s

#4 [builder 1/7] FROM docker.io/library/ubuntu:22.04@sha256:01a3ee0b5e413cefaaffc6abe68c9c37879ae3cced56a8e088b1649e5b269eee
#4 resolve docker.io/library/ubuntu:22.04@sha256:01a3ee0b5e413cefaaffc6abe68c9c37879ae3cced56a8e088b1649e5b269eee done
#4 CACHED

#5 [internal] load build context
#5 transferring context: 372B done
#5 DONE 0.0s

#6 [builder 2/7] RUN apt-get update &&     apt-get install -y --no-install-recommends ca-certificates curl &&     rm -rf /var/lib/apt/lists/*
#6 0.393 Get:1 http://archive.ubuntu.com/ubuntu jammy InRelease [270 kB]
#6 0.396 Get:2 http://security.ubuntu.com/ubuntu jammy-security InRelease [129 kB]
#6 0.644 Get:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [128 kB]
#6 0.847 Get:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [127 kB]
#6 1.223 Get:5 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [3024 kB]
#6 1.671 Get:6 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [47.7 kB]
#6 1.808 Get:7 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [17.5 MB]
#6 1.846 Get:8 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [1253 kB]
#6 2.212 Get:9 http://security.ubuntu.com/ubuntu jammy-security/restricted amd64 Packages [4532 kB]
#6 7.750 Get:10 http://archive.ubuntu.com/ubuntu jammy/main amd64 Packages [1792 kB]
#6 8.108 Get:11 http://archive.ubuntu.com/ubuntu jammy/restricted amd64 Packages [164 kB]
#6 8.324 Get:12 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [266 kB]
#6 9.080 Get:13 http://archive.ubuntu.com/ubuntu jammy-updates/multiverse amd64 Packages [55.7 kB]
#6 9.796 Get:14 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [3340 kB]
#6 10.17 Get:15 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages [1561 kB]
#6 10.51 Get:16 http://archive.ubuntu.com/ubuntu jammy-updates/restricted amd64 Packages [4703 kB]
#6 11.05 Get:17 http://archive.ubuntu.com/ubuntu jammy-backports/main amd64 Packages [83.2 kB]
#6 11.24 Get:18 http://archive.ubuntu.com/ubuntu jammy-backports/universe amd64 Packages [35.2 kB]
#6 11.31 Fetched 39.0 MB in 11s (3514 kB/s)
#6 11.31 Reading package lists...
#6 12.05 Reading package lists...
#6 12.68 Building dependency tree...
#6 12.82 Reading state information...
#6 12.92 The following additional packages will be installed:
#6 12.92   libbrotli1 libcurl4 libldap-2.5-0 libnghttp2-14 libpsl5 librtmp1 libsasl2-2
#6 12.92   libsasl2-modules-db libssh-4 openssl
#6 12.92 Recommended packages:
#6 12.92   libldap-common publicsuffix libsasl2-modules
#6 12.97 The following NEW packages will be installed:
#6 12.97   ca-certificates curl libbrotli1 libcurl4 libldap-2.5-0 libnghttp2-14 libpsl5
#6 12.97   librtmp1 libsasl2-2 libsasl2-modules-db libssh-4 openssl
#6 13.17 0 upgraded, 12 newly installed, 0 to remove and 6 not upgraded.
#6 13.17 Need to get 2784 kB of archives.
#6 13.17 After this operation, 6376 kB of additional disk space will be used.
#6 13.17 Get:1 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 openssl amd64 3.0.2-0ubuntu1.19 [1186 kB]
#6 13.47 Get:2 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 ca-certificates all 20240203~22.04.1 [162 kB]
#6 13.69 Get:3 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libnghttp2-14 amd64 1.43.0-1ubuntu0.2 [76.9 kB]
#6 13.87 Get:4 http://archive.ubuntu.com/ubuntu jammy/main amd64 libpsl5 amd64 0.21.0-1.2build2 [58.4 kB]
#6 14.05 Get:5 http://archive.ubuntu.com/ubuntu jammy/main amd64 libbrotli1 amd64 1.0.9-2build6 [315 kB]
#6 14.34 Get:6 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libsasl2-modules-db amd64 2.1.27+dfsg2-3ubuntu1.2 [20.5 kB]
#6 15.00 Get:7 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libsasl2-2 amd64 2.1.27+dfsg2-3ubuntu1.2 [53.8 kB]
#6 15.18 Get:8 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libldap-2.5-0 amd64 2.5.19+dfsg-0ubuntu0.22.04.1 [184 kB]
#6 15.98 Get:9 http://archive.ubuntu.com/ubuntu jammy/main amd64 librtmp1 amd64 2.4+20151223.gitfa8646d.1-2build4 [58.2 kB]
#6 16.17 Get:10 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libssh-4 amd64 0.9.6-2ubuntu0.22.04.3 [186 kB]
#6 17.38 Get:11 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libcurl4 amd64 7.81.0-1ubuntu1.20 [289 kB]
#6 17.64 Get:12 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 curl amd64 7.81.0-1ubuntu1.20 [194 kB]
#6 17.89 debconf: delaying package configuration, since apt-utils is not installed
#6 17.93 Fetched 2784 kB in 5s (587 kB/s)
#6 17.99 Selecting previously unselected package openssl.
#6 17.99 (Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 4393 files and directories currently installed.)
#6 18.00 Preparing to unpack .../00-openssl_3.0.2-0ubuntu1.19_amd64.deb ...
#6 18.00 Unpacking openssl (3.0.2-0ubuntu1.19) ...
#6 18.09 Selecting previously unselected package ca-certificates.
#6 18.09 Preparing to unpack .../01-ca-certificates_20240203~22.04.1_all.deb ...
#6 18.10 Unpacking ca-certificates (20240203~22.04.1) ...
#6 18.18 Selecting previously unselected package libnghttp2-14:amd64.
#6 18.18 Preparing to unpack .../02-libnghttp2-14_1.43.0-1ubuntu0.2_amd64.deb ...
#6 18.19 Unpacking libnghttp2-14:amd64 (1.43.0-1ubuntu0.2) ...
#6 18.26 Selecting previously unselected package libpsl5:amd64.
#6 18.26 Preparing to unpack .../03-libpsl5_0.21.0-1.2build2_amd64.deb ...
#6 18.26 Unpacking libpsl5:amd64 (0.21.0-1.2build2) ...
#6 18.33 Selecting previously unselected package libbrotli1:amd64.
#6 18.33 Preparing to unpack .../04-libbrotli1_1.0.9-2build6_amd64.deb ...
#6 18.33 Unpacking libbrotli1:amd64 (1.0.9-2build6) ...
#6 18.41 Selecting previously unselected package libsasl2-modules-db:amd64.
#6 18.41 Preparing to unpack .../05-libsasl2-modules-db_2.1.27+dfsg2-3ubuntu1.2_amd64.deb ...
#6 18.41 Unpacking libsasl2-modules-db:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#6 18.48 Selecting previously unselected package libsasl2-2:amd64.
#6 18.48 Preparing to unpack .../06-libsasl2-2_2.1.27+dfsg2-3ubuntu1.2_amd64.deb ...
#6 18.48 Unpacking libsasl2-2:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#6 18.55 Selecting previously unselected package libldap-2.5-0:amd64.
#6 18.55 Preparing to unpack .../07-libldap-2.5-0_2.5.19+dfsg-0ubuntu0.22.04.1_amd64.deb ...
#6 18.55 Unpacking libldap-2.5-0:amd64 (2.5.19+dfsg-0ubuntu0.22.04.1) ...
#6 18.63 Selecting previously unselected package librtmp1:amd64.
#6 18.63 Preparing to unpack .../08-librtmp1_2.4+20151223.gitfa8646d.1-2build4_amd64.deb ...
#6 18.63 Unpacking librtmp1:amd64 (2.4+20151223.gitfa8646d.1-2build4) ...
#6 18.70 Selecting previously unselected package libssh-4:amd64.
#6 18.70 Preparing to unpack .../09-libssh-4_0.9.6-2ubuntu0.22.04.3_amd64.deb ...
#6 18.70 Unpacking libssh-4:amd64 (0.9.6-2ubuntu0.22.04.3) ...
#6 18.77 Selecting previously unselected package libcurl4:amd64.
#6 18.77 Preparing to unpack .../10-libcurl4_7.81.0-1ubuntu1.20_amd64.deb ...
#6 18.77 Unpacking libcurl4:amd64 (7.81.0-1ubuntu1.20) ...
#6 18.84 Selecting previously unselected package curl.
#6 18.85 Preparing to unpack .../11-curl_7.81.0-1ubuntu1.20_amd64.deb ...
#6 18.85 Unpacking curl (7.81.0-1ubuntu1.20) ...
#6 18.91 Setting up libpsl5:amd64 (0.21.0-1.2build2) ...
#6 18.91 Setting up libbrotli1:amd64 (1.0.9-2build6) ...
#6 18.91 Setting up libnghttp2-14:amd64 (1.43.0-1ubuntu0.2) ...
#6 18.92 Setting up libsasl2-modules-db:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#6 18.92 Setting up librtmp1:amd64 (2.4+20151223.gitfa8646d.1-2build4) ...
#6 18.93 Setting up libsasl2-2:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#6 18.93 Setting up libssh-4:amd64 (0.9.6-2ubuntu0.22.04.3) ...
#6 18.93 Setting up openssl (3.0.2-0ubuntu1.19) ...
#6 18.95 Setting up libldap-2.5-0:amd64 (2.5.19+dfsg-0ubuntu0.22.04.1) ...
#6 18.95 Setting up ca-certificates (20240203~22.04.1) ...
#6 23.14 Updating certificates in /etc/ssl/certs...
#6 29.92 146 added, 0 removed; done.
#6 29.97 Setting up libcurl4:amd64 (7.81.0-1ubuntu1.20) ...
#6 29.97 Setting up curl (7.81.0-1ubuntu1.20) ...
#6 29.98 Processing triggers for libc-bin (2.35-0ubuntu3.10) ...
#6 30.02 Processing triggers for ca-certificates (20240203~22.04.1) ...
#6 30.06 Updating certificates in /etc/ssl/certs...
#6 35.51 0 added, 0 removed; done.
#6 35.51 Running hooks in /etc/ca-certificates/update.d...
#6 35.52 done.
#6 DONE 35.7s

#7 [builder 3/7] RUN mkdir -p /pwb-staging &&     RSW_VERSION_URL=$(echo -n "2025.08.0-daily+223.pro3" | sed 's/+/-/g') &&     curl -fsSL -o /pwb-staging/rsp-session-multi-linux.tar.gz "https://s3.amazonaws.com/rstudio-ide-build/session/multi/x86_64/rsp-session-multi-linux-${RSW_VERSION_URL}-x86_64.tar.gz" &&     mkdir -p /opt/session-components &&     tar -C /opt/session-components -xpf /pwb-staging/rsp-session-multi-linux.tar.gz &&     chmod 755 /opt/session-components &&     rm -rf /pwb-staging
#7 DONE 30.3s

#8 [builder 4/7] RUN if [ -f "/opt/session-components/bin/session-init" ]; then         echo "Using packaged session-init binary";         mkdir -p /workspace &&         cp /opt/session-components/bin/session-init /workspace/entrypoint;     else         echo "Building session-init from source for backwards compatibility";     fi
#8 0.224 Using packaged session-init binary
#8 DONE 0.3s

#9 [builder 5/7] RUN if [ ! -f "/workspace/entrypoint" ]; then         echo "Installing Go 1.22.2";         curl -fsSL -o /tmp/go.tar.gz "https://go.dev/dl/go1.22.2.linux-amd64.tar.gz" &&         tar -C /usr/local -xf /tmp/go.tar.gz;     fi
#9 DONE 0.2s

#10 [builder 6/7] COPY entrypoint/ /workspace/
#10 DONE 0.0s

#11 [builder 7/7] RUN if [ ! -f "/workspace/entrypoint" ]; then         echo "Building entrypoint";         export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin &&         cd /workspace &&         go mod download &&         CGO_ENABLED=0 GOOS=linux go build -ldflags '-s -w' -o /workspace/entrypoint main.go;     fi
#11 DONE 0.1s

#12 [build 3/4] COPY --from=builder --chmod=755 /workspace/entrypoint /usr/local/bin/entrypoint
#12 DONE 0.0s

#13 [build 4/4] COPY --from=builder --chmod=755 /opt/session-components /opt/session-components
#13 DONE 4.3s

#14 exporting to image
#14 exporting layers
#14 exporting layers 33.3s done
#14 exporting manifest sha256:80fa7ac59e0cc385aab6bb7055f04781ee101d0efd4bf1fb094f244c00c95f69
#14 exporting manifest sha256:80fa7ac59e0cc385aab6bb7055f04781ee101d0efd4bf1fb094f244c00c95f69 0.0s done
#14 exporting config sha256:dc96fd6574690246aaed9b0a2426013c459d667a3e40d1766f5c2820b2782f1f 0.0s done
#14 exporting attestation manifest sha256:03f86da1c9b3de1ad02c7fa89d01bc64f4af8d882dc34a7efa36b6729c1ca8f9 0.0s done
#14 exporting manifest list sha256:a26d673c8bc227a58af001b95abc6033a3e00e48abefabcd2806a0a504c88d79 0.0s done
#14 naming to moby-dangling@sha256:a26d673c8bc227a58af001b95abc6033a3e00e48abefabcd2806a0a504c88d79 done
#14 DONE 33.4s
Build with backwards compatibility
#0 building with "desktop-linux" instance using docker driver

#1 [internal] load build definition from Dockerfile.ubuntu2204
#1 transferring dockerfile: 2.59kB done
#1 DONE 0.0s

#2 [internal] load metadata for docker.io/library/ubuntu:22.04
#2 ...

#3 [auth] library/ubuntu:pull token for registry-1.docker.io
#3 DONE 0.0s

#2 [internal] load metadata for docker.io/library/ubuntu:22.04
#2 DONE 0.5s

#4 [internal] load .dockerignore
#4 transferring context: 2B done
#4 DONE 0.0s

#5 [builder 1/7] FROM docker.io/library/ubuntu:22.04@sha256:01a3ee0b5e413cefaaffc6abe68c9c37879ae3cced56a8e088b1649e5b269eee
#5 resolve docker.io/library/ubuntu:22.04@sha256:01a3ee0b5e413cefaaffc6abe68c9c37879ae3cced56a8e088b1649e5b269eee done
#5 CACHED

#6 [internal] load build context
#6 transferring context: 372B done
#6 DONE 0.0s

#7 [builder 2/7] RUN apt-get update &&     apt-get install -y --no-install-recommends ca-certificates curl &&     rm -rf /var/lib/apt/lists/*
#7 0.443 Get:1 http://archive.ubuntu.com/ubuntu jammy InRelease [270 kB]
#7 0.458 Get:2 http://security.ubuntu.com/ubuntu jammy-security InRelease [129 kB]
#7 0.684 Get:3 http://archive.ubuntu.com/ubuntu jammy-updates InRelease [128 kB]
#7 0.945 Get:4 http://archive.ubuntu.com/ubuntu jammy-backports InRelease [127 kB]
#7 1.272 Get:5 http://security.ubuntu.com/ubuntu jammy-security/universe amd64 Packages [1253 kB]
#7 1.809 Get:6 http://archive.ubuntu.com/ubuntu jammy/restricted amd64 Packages [164 kB]
#7 1.995 Get:7 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages [3024 kB]
#7 2.124 Get:8 http://archive.ubuntu.com/ubuntu jammy/universe amd64 Packages [17.5 MB]
#7 2.701 Get:9 http://security.ubuntu.com/ubuntu jammy-security/restricted amd64 Packages [4532 kB]
#7 3.989 Get:10 http://archive.ubuntu.com/ubuntu jammy/main amd64 Packages [1792 kB]
#7 4.450 Get:11 http://security.ubuntu.com/ubuntu jammy-security/multiverse amd64 Packages [47.7 kB]
#7 4.802 Get:12 http://archive.ubuntu.com/ubuntu jammy/multiverse amd64 Packages [266 kB]
#7 5.142 Get:13 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages [3340 kB]
#7 5.813 Get:14 http://archive.ubuntu.com/ubuntu jammy-updates/restricted amd64 Packages [4703 kB]
#7 6.585 Get:15 http://archive.ubuntu.com/ubuntu jammy-updates/multiverse amd64 Packages [55.7 kB]
#7 6.845 Get:16 http://archive.ubuntu.com/ubuntu jammy-updates/universe amd64 Packages [1561 kB]
#7 7.569 Get:17 http://archive.ubuntu.com/ubuntu jammy-backports/universe amd64 Packages [35.2 kB]
#7 7.786 Get:18 http://archive.ubuntu.com/ubuntu jammy-backports/main amd64 Packages [83.2 kB]
#7 7.836 Fetched 39.0 MB in 8s (5136 kB/s)
#7 7.836 Reading package lists...
#7 8.551 Reading package lists...
#7 9.241 Building dependency tree...
#7 9.433 Reading state information...
#7 9.569 The following additional packages will be installed:
#7 9.569   libbrotli1 libcurl4 libldap-2.5-0 libnghttp2-14 libpsl5 librtmp1 libsasl2-2
#7 9.570   libsasl2-modules-db libssh-4 openssl
#7 9.571 Recommended packages:
#7 9.571   libldap-common publicsuffix libsasl2-modules
#7 9.623 The following NEW packages will be installed:
#7 9.623   ca-certificates curl libbrotli1 libcurl4 libldap-2.5-0 libnghttp2-14 libpsl5
#7 9.623   librtmp1 libsasl2-2 libsasl2-modules-db libssh-4 openssl
#7 9.866 0 upgraded, 12 newly installed, 0 to remove and 6 not upgraded.
#7 9.866 Need to get 2784 kB of archives.
#7 9.866 After this operation, 6376 kB of additional disk space will be used.
#7 9.866 Get:1 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 openssl amd64 3.0.2-0ubuntu1.19 [1186 kB]
#7 10.14 Get:2 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 ca-certificates all 20240203~22.04.1 [162 kB]
#7 10.38 Get:3 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libnghttp2-14 amd64 1.43.0-1ubuntu0.2 [76.9 kB]
#7 10.56 Get:4 http://archive.ubuntu.com/ubuntu jammy/main amd64 libpsl5 amd64 0.21.0-1.2build2 [58.4 kB]
#7 10.74 Get:5 http://archive.ubuntu.com/ubuntu jammy/main amd64 libbrotli1 amd64 1.0.9-2build6 [315 kB]
#7 11.08 Get:6 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libsasl2-modules-db amd64 2.1.27+dfsg2-3ubuntu1.2 [20.5 kB]
#7 11.24 Get:7 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libsasl2-2 amd64 2.1.27+dfsg2-3ubuntu1.2 [53.8 kB]
#7 11.44 Get:8 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libldap-2.5-0 amd64 2.5.19+dfsg-0ubuntu0.22.04.1 [184 kB]
#7 12.28 Get:9 http://archive.ubuntu.com/ubuntu jammy/main amd64 librtmp1 amd64 2.4+20151223.gitfa8646d.1-2build4 [58.2 kB]
#7 12.48 Get:10 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libssh-4 amd64 0.9.6-2ubuntu0.22.04.3 [186 kB]
#7 12.67 Get:11 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 libcurl4 amd64 7.81.0-1ubuntu1.20 [289 kB]
#7 12.91 Get:12 http://archive.ubuntu.com/ubuntu jammy-updates/main amd64 curl amd64 7.81.0-1ubuntu1.20 [194 kB]
#7 13.19 debconf: delaying package configuration, since apt-utils is not installed
#7 13.23 Fetched 2784 kB in 3s (816 kB/s)
#7 13.30 Selecting previously unselected package openssl.
#7 13.30 (Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 4393 files and directories currently installed.)
#7 13.30 Preparing to unpack .../00-openssl_3.0.2-0ubuntu1.19_amd64.deb ...
#7 13.31 Unpacking openssl (3.0.2-0ubuntu1.19) ...
#7 13.40 Selecting previously unselected package ca-certificates.
#7 13.41 Preparing to unpack .../01-ca-certificates_20240203~22.04.1_all.deb ...
#7 13.41 Unpacking ca-certificates (20240203~22.04.1) ...
#7 13.49 Selecting previously unselected package libnghttp2-14:amd64.
#7 13.49 Preparing to unpack .../02-libnghttp2-14_1.43.0-1ubuntu0.2_amd64.deb ...
#7 13.49 Unpacking libnghttp2-14:amd64 (1.43.0-1ubuntu0.2) ...
#7 13.56 Selecting previously unselected package libpsl5:amd64.
#7 13.56 Preparing to unpack .../03-libpsl5_0.21.0-1.2build2_amd64.deb ...
#7 13.56 Unpacking libpsl5:amd64 (0.21.0-1.2build2) ...
#7 13.63 Selecting previously unselected package libbrotli1:amd64.
#7 13.63 Preparing to unpack .../04-libbrotli1_1.0.9-2build6_amd64.deb ...
#7 13.63 Unpacking libbrotli1:amd64 (1.0.9-2build6) ...
#7 13.70 Selecting previously unselected package libsasl2-modules-db:amd64.
#7 13.70 Preparing to unpack .../05-libsasl2-modules-db_2.1.27+dfsg2-3ubuntu1.2_amd64.deb ...
#7 13.70 Unpacking libsasl2-modules-db:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#7 13.77 Selecting previously unselected package libsasl2-2:amd64.
#7 13.77 Preparing to unpack .../06-libsasl2-2_2.1.27+dfsg2-3ubuntu1.2_amd64.deb ...
#7 13.77 Unpacking libsasl2-2:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#7 13.84 Selecting previously unselected package libldap-2.5-0:amd64.
#7 13.84 Preparing to unpack .../07-libldap-2.5-0_2.5.19+dfsg-0ubuntu0.22.04.1_amd64.deb ...
#7 13.84 Unpacking libldap-2.5-0:amd64 (2.5.19+dfsg-0ubuntu0.22.04.1) ...
#7 13.91 Selecting previously unselected package librtmp1:amd64.
#7 13.91 Preparing to unpack .../08-librtmp1_2.4+20151223.gitfa8646d.1-2build4_amd64.deb ...
#7 13.91 Unpacking librtmp1:amd64 (2.4+20151223.gitfa8646d.1-2build4) ...
#7 13.98 Selecting previously unselected package libssh-4:amd64.
#7 13.98 Preparing to unpack .../09-libssh-4_0.9.6-2ubuntu0.22.04.3_amd64.deb ...
#7 13.98 Unpacking libssh-4:amd64 (0.9.6-2ubuntu0.22.04.3) ...
#7 14.05 Selecting previously unselected package libcurl4:amd64.
#7 14.05 Preparing to unpack .../10-libcurl4_7.81.0-1ubuntu1.20_amd64.deb ...
#7 14.05 Unpacking libcurl4:amd64 (7.81.0-1ubuntu1.20) ...
#7 14.12 Selecting previously unselected package curl.
#7 14.12 Preparing to unpack .../11-curl_7.81.0-1ubuntu1.20_amd64.deb ...
#7 14.12 Unpacking curl (7.81.0-1ubuntu1.20) ...
#7 14.18 Setting up libpsl5:amd64 (0.21.0-1.2build2) ...
#7 14.18 Setting up libbrotli1:amd64 (1.0.9-2build6) ...
#7 14.19 Setting up libnghttp2-14:amd64 (1.43.0-1ubuntu0.2) ...
#7 14.19 Setting up libsasl2-modules-db:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#7 14.19 Setting up librtmp1:amd64 (2.4+20151223.gitfa8646d.1-2build4) ...
#7 14.20 Setting up libsasl2-2:amd64 (2.1.27+dfsg2-3ubuntu1.2) ...
#7 14.20 Setting up libssh-4:amd64 (0.9.6-2ubuntu0.22.04.3) ...
#7 14.20 Setting up openssl (3.0.2-0ubuntu1.19) ...
#7 14.22 Setting up libldap-2.5-0:amd64 (2.5.19+dfsg-0ubuntu0.22.04.1) ...
#7 14.22 Setting up ca-certificates (20240203~22.04.1) ...
#7 18.60 Updating certificates in /etc/ssl/certs...
#7 25.33 146 added, 0 removed; done.
#7 25.39 Setting up libcurl4:amd64 (7.81.0-1ubuntu1.20) ...
#7 25.39 Setting up curl (7.81.0-1ubuntu1.20) ...
#7 25.40 Processing triggers for libc-bin (2.35-0ubuntu3.10) ...
#7 25.45 Processing triggers for ca-certificates (20240203~22.04.1) ...
#7 25.50 Updating certificates in /etc/ssl/certs...
#7 30.86 0 added, 0 removed; done.
#7 30.86 Running hooks in /etc/ca-certificates/update.d...
#7 30.87 done.
#7 DONE 31.0s

#8 [builder 3/7] RUN mkdir -p /pwb-staging &&     RSW_VERSION_URL=$(echo -n "2025.08.0-daily+223.pro3" | sed 's/+/-/g') &&     curl -fsSL -o /pwb-staging/rsp-session-multi-linux.tar.gz "https://s3.amazonaws.com/rstudio-ide-build/session/multi/x86_64/rsp-session-multi-linux-${RSW_VERSION_URL}-x86_64.tar.gz" &&     mkdir -p /opt/session-components &&     tar -C /opt/session-components -xpf /pwb-staging/rsp-session-multi-linux.tar.gz &&     chmod 755 /opt/session-components &&     rm -rf /pwb-staging
#8 DONE 52.2s

#9 [builder 4/7] RUN if [ -f "/opt/session-components/bin/session-init" ]; then         echo "Using packaged session-init binary";         mkdir -p /workspace &&         cp /opt/session-components/bin/session-init /workspace/entrypoint;     else         echo "Building session-init from source for backwards compatibility";     fi
#9 0.268 Using packaged session-init binary
#9 DONE 0.3s

#10 [builder 5/7] RUN if [ ! -f "/workspace/entrypoint" ]; then         echo "Installing Go 1.22.2";         curl -fsSL -o /tmp/go.tar.gz "https://go.dev/dl/go1.22.2.linux-amd64.tar.gz" &&         tar -C /usr/local -xf /tmp/go.tar.gz;     fi
#10 DONE 0.2s

#11 [builder 6/7] COPY entrypoint/ /workspace/
#11 DONE 0.0s

#12 [builder 7/7] RUN if [ ! -f "/workspace/entrypoint" ]; then         echo "Building entrypoint";         export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin &&         cd /workspace &&         go mod download &&         CGO_ENABLED=0 GOOS=linux go build -ldflags '-s -w' -o /workspace/entrypoint main.go;     fi
#12 DONE 0.1s

#13 [build 3/4] COPY --from=builder --chmod=755 /workspace/entrypoint /usr/local/bin/entrypoint
#13 DONE 0.0s

#14 [build 4/4] COPY --from=builder --chmod=755 /opt/session-components /opt/session-components
#14 DONE 10.1s

#15 exporting to image
#15 exporting layers
#15 exporting layers 36.2s done
#15 exporting manifest sha256:3cc08f904dfae5fd32a843b2a0cadfef875632f79c5bb9fefd78522642907e94
#15 exporting manifest sha256:3cc08f904dfae5fd32a843b2a0cadfef875632f79c5bb9fefd78522642907e94 0.1s done
#15 exporting config sha256:1ce1cc2c494b1b38ce14350e7aeb85819c99f5070b48528488e5298d258c614e 0.0s done
#15 exporting attestation manifest sha256:19b32504f52c9ca36b2291a94f5b0c6a338206ce90d0522719622b7e34b33095 0.0s done
#15 exporting manifest list sha256:93716786be178751ea2e9ca2444cb159fb92de4171353b20f654bf930de8dab2 done
#15 naming to moby-dangling@sha256:93716786be178751ea2e9ca2444cb159fb92de4171353b20f654bf930de8dab2 done
#15 DONE 36.3s

Copy link
Contributor

@skyeturriff skyeturriff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

@zachhannum zachhannum merged commit 1405e01 into dev Jun 23, 2025
42 checks passed
@zachhannum zachhannum deleted the zh-session-init-built-in-entrypoint branch June 23, 2025 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants