slimtoolkit / slimtoolkit/slim

After slimming down, many environments are gone and the operation fails.

Open
#686 0 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
23.4k
Forks
840
PR merge metrics
No merged PRs in 30d

Description

run:docker-slim build --http-probe=false lui_label:v1
cmd=build info=exec message='changing continue-after from probe to nothing because http-probe is disabled'
cmd=build info=exec message='changing continue-after to enter'
cmd=build state=started
cmd=build info=params target.image='lui_label:v1' continue.mode='enter' rt.as.user='true' keep.perms='true' tags='' image-build-engine='internal' target.type='image'
cmd=build state=image.inspection.start
cmd=build info=image size.bytes='29592992698' size.human='30 GB' id='sha256:8b94a9be17f599791890905463c523742dad41c7c315ad3bc1e814a09d109989'
cmd=build info=image.stack index='0' name='lui_label:v1' id='sha256:8b94a9be17f599791890905463c523742dad41c7c315ad3bc1e814a09d109989'
cmd=build info=image.exposed_ports list='22/tcp'
cmd=build state=image.inspection.done
cmd=build state=container.inspection.start
cmd=build info=container status='created' name='slimk_3922407_20240529070544' id='dd4ce71728d925ae22cc395960b52fd42ece51ac1740c9e2f674161ab764fba0'
cmd=build info=container id='dd4ce71728d925ae22cc395960b52fd42ece51ac1740c9e2f674161ab764fba0' status='running' name='slimk_3922407_20240529070544'
cmd=build info=container message='obtained IP address' ip='172.17.0.4'
time="2024-05-29T15:05:46+08:00" level=error msg="channel.Client.Read: read error (read tcp 127.0.0.1:38232->127.0.0.1:32778: read: connection reset by peer), exiting..."
time="2024-05-29T15:05:46+08:00" level=error msg="channel.NewCommandClient: channel verify error = read tcp 127.0.0.1:38232->127.0.0.1:32778: read: connection reset by peer"
cmd=build info=cmd.startmonitor status='sent'
cmd=build info=event.startmonitor.done status='received'
cmd=build info=container name='slimk_3922407_20240529070544' id='dd4ce71728d925ae22cc395960b52fd42ece51ac1740c9e2f674161ab764fba0' target.port.list='32779' target.port.info='22/tcp => 0.0.0.0:32779' message='YOU CAN USE THESE PORTS TO INTERACT WITH THE CONTAINER'
cmd=build info=continue.after mode='enter' message='provide the expected input to allow the container inspector to continue its execution'
cmd=build prompt='USER INPUT REQUIRED, PRESS WHEN YOU ARE DONE USING THE CONTAINER'
docker exec -it lui:lable sh
cmd=build state=container.inspection.finishing
enter

cmd=build state=container.inspection.artifact.processing
cmd=build state=container.inspection.done
cmd=build state=building message="building optimized image" engine=internal
cmd=build state=completed
cmd=build info=results by='4.72X' size.original='30 GB' size.optimized='6.3 GB' status='MINIFIED'
cmd=build info=results image.id='sha256:db4bcae6c6286bab008b00779ec5d0f9c823ae2836701417ec2e2092eee48a08' image.digest='sha256:6a37dbde71906cf1b869490d83668bcdc6a1a9709c3cef360fee4dc86337a19f' has.data='true' image-build-engine='internal' image.name='lui_label.slim' image.size='6.3 GB'
cmd=build info=results artifacts.location='/tmp/slim-state/.slim-state/images/8b94a9be17f599791890905463c523742dad41c7c315ad3bc1e814a09d109989/artifacts'
cmd=build info=results artifacts.report='creport.json'
cmd=build info=results artifacts.dockerfile.reversed='Dockerfile.reversed'
cmd=build info=results artifacts.seccomp='lui_label-seccomp.json'
cmd=build info=results artifacts.apparmor='lui_label-apparmor-profile'
cmd=build state=done
cmd=build info=commands message='use the xray command to learn more about the optimize image'
cmd=build info=report file='slim.report.json'
app='slim' message='GitHub Discussions' info='https://github.com/slimtoolkit/slim/discussions'
app='slim' message='Join the CNCF Slack channel to ask questions or to share your feedback' info='https://cloud-native.slack.com/archives/C059QP1RH1S'
app='slim' message='Join the Discord server to ask questions or to share your feedback' info='https://discord.gg/9tDyxYS'
app='slim' message='Join the Gitter channel to ask questions or to share your feedback' info='https://gitter.im/docker-slim/community'

docker logs:
/usr/lib/python3/dist-packages/requests/init.py:89: RequestsDependencyWarning: urllib3 (2.2.1) or chardet (3.0.4) doesn't match a supported version!
warnings.warn("urllib3 ({}) or chardet ({}) doesn't match a supported "
Traceback (most recent call last):
File "/paddle/server_fast.py", line 7, in
from model_infer import text_cls
File "/paddle/model_infer.py", line 5, in
from fast_uie import LUI_UIE
File "/paddle/fast_uie.py", line 4, in
import distutils.util
ModuleNotFoundError: No module named 'distutils'

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported docker-slim build --http-probe=false lui_label:v1 command and compare the original and optimized container logs. Investigate the reported ModuleNotFoundError: No module named 'distutils'; done means the optimized image retains the environment needed for the application to start.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, python
Domain
devops, infrastructure
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.