Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use debian bookworm in docker container #1311

Merged
merged 4 commits into from
Nov 19, 2024
Merged

use debian bookworm in docker container #1311

merged 4 commits into from
Nov 19, 2024

Conversation

paulfitz
Copy link
Member

This returns to an upgrade first attempted in:
#1255
That upgrade ran into sandbox trouble, which eventually proved to be a small change in the layout of directories in bookworm relative to buster (/lib64 became a symlink).

Context

The base image used for Grist was getting quite old, along with the node version used.

Proposed solution

This applies the upgrade and simply skips exposing /lib64 in the sandbox if it is a symlink. If it is a symlink, then sandboxes will not survive being snapshotted and restored.

Related issues

Has this been tested?

Tested manually, and with PYTHON_VERSION_ON_CREATION=2 and 3 following #1300

@@ -162,7 +168,7 @@ def preserve(*locations, short_failure=False):

preserve("/usr/local/lib")
if os.path.exists('/lib64'):
Copy link
Member

Choose a reason for hiding this comment

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

Would it be clearer to add the condition and explanation directly here: if os.path.exists('/lib64') and not os.path.islink('/lib64')?

Copy link
Member Author

Choose a reason for hiding this comment

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

Good idea, made that change.

This returns to an upgrade first attempted in:
  #1255
That upgrade ran into sandbox trouble, which eventually proved to
be a small change in the layout of directories in bookworm relative
to buster (`/lib64` became a symlink).
@paulfitz
Copy link
Member Author

There is a deprecation warning on all calls to node now:

(node:3256118) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)

I tried upgrading packages and it started looking a little messy, so I'm leaving it as separate work, with deprecation messages turned off in the container. Developers will see them all the time and it should be annoying enough to ensure we deal with it. The deprecation is for code that may be leaving node in future versions.

@paulfitz
Copy link
Member Author

Added some workflow steps to duplicate tests @jonathanperret did manually, to increate odds of catching sandbox breakage in future (at least at the point of updating docker images). Tested manually on repo fork.

@paulfitz paulfitz requested a review from dsagal November 18, 2024 21:38
Copy link
Member

@dsagal dsagal left a comment

Choose a reason for hiding this comment

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

All makes sense, thanks! Just one request for a comment.

pip2 install -r requirements.txt

pip2 install -r requirements.txt && \
find /usr/lib -iname "libffi.so.6*" -exec cp {} /usr/local/lib \;
Copy link
Member

Choose a reason for hiding this comment

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

Could a comment be added about this? Like which piece/version needs it, and how to tell when some day it may no longer be needed.

Copy link
Member Author

Choose a reason for hiding this comment

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

Comment added.

@paulfitz paulfitz requested a review from dsagal November 19, 2024 14:41
Copy link
Member

@dsagal dsagal left a comment

Choose a reason for hiding this comment

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

Thank you!

@paulfitz paulfitz merged commit 26d3ecd into main Nov 19, 2024
11 checks passed
@paulfitz paulfitz deleted the paulfitz/bookworm branch November 19, 2024 15:12
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.

2 participants