- 
                Notifications
    You must be signed in to change notification settings 
- Fork 8
Add Dockerfile with minimal supported Python version (3.10) #16
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| FROM python:3.10-slim | ||
|  | ||
| RUN REQUIRED_PKGS=' \ | ||
| ca-certificates \ | ||
| curl \ | ||
| git \ | ||
| unzip \ | ||
| 
      Comment on lines
    
      +4
     to 
      +7
    
   There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 
 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the review, 
 For  For most of them, true, we can decide if we want to keep them or not. Let me know what you'd prefer. | ||
| ' \ | ||
| && apt-get update \ | ||
| && apt-get install --no-install-recommends --yes ${REQUIRED_PKGS} \ | ||
| && apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \ | ||
| && rm -rf /var/lib/apt/lists/* | ||
| 
      Comment on lines
    
      +11
     to 
      +12
    
   There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think  There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You need to purge all installed dependencies pull from the packages we want, as well as unused packages. This is what the line 11 does. I might have kept the line 11 because I found out that there was no need to uninstall tools provisioned for installation what we want ( | ||
|  | ||
| ARG ASDF_VERSION="v0.16.7" | ||
| ENV ASDF_DATA_DIR="/opt/asdf-data" | ||
| ENV ASDF_INSTALL_DIR="/opt/asdf" | ||
| ENV PATH="${ASDF_DATA_DIR}/shims:${ASDF_INSTALL_DIR}/bin:${PATH}" | ||
|  | ||
| RUN git clone \ | ||
| --branch "${ASDF_VERSION}" \ | ||
| --depth=1 \ | ||
| https://github.com/asdf-vm/asdf.git "${ASDF_INSTALL_DIR}" \ | ||
| && asdf --help | ||
|  | ||
| RUN asdf plugin add tfswitch \ | ||
| && asdf install tfswitch latest \ | ||
| && asdf global tfswitch latest \ | ||
| && tfswitch --latest | ||
| 
      Comment on lines
    
      +14
     to 
      +28
    
   There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This doesn't belong to Stacks and shouldn't be part of this image. May I suggest removing this from the Stacks Dockerfile and then building an image  There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You don't need Terraform for running  Indeed,  | ||
|  | ||
| RUN apt-get update \ | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This  There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What do you mean ? If there is no cache file in  | ||
| && pip install git+https://github.com/tchemineau/cisco-thousandeyes-stacks.git@provides-dockerfile \ | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 
 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks. Good point for the URL. Only submitted to get a review first, indeed this should be from master repo. | ||
| && stacks --help | ||
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
|  | @@ -9,7 +9,6 @@ dependencies = [ | |
| "cryptography>=43.0.3", | ||
| "deepmerge>=2.0", | ||
| "gitpython>=3.1.43", | ||
| "importlib>=1.0.4", | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why are we removing  There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Because the installation of the  | ||
| "jinja2>=3.1.4", | ||
| "packaging>=24.2", | ||
| "python-hcl2<6.0.0", # https://github.com/amplify-education/python-hcl2/issues/183 | ||
|  | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.