Skip to content

Commit

Permalink
sagemathgh-38049: Fix broken docker/Dockerfile
Browse files Browse the repository at this point in the history
<!-- ^ Please provide a concise and informative title. -->
<!-- ^ Don't put issue numbers in the title, do this in the PR
description below. -->
<!-- ^ For example, instead of "Fixes sagemath#12345" use "Introduce new method
to calculate 1 + 2". -->
<!-- v Describe your changes below in detail. -->
<!-- v Why is this change required? What problem does it solve? -->
<!-- v If this PR resolves an open issue, please link to it here. For
example, "Fixes sagemath#12345". -->

As mentioned in
sagemath#37856 (comment) the
`Dockerfile`  is broken by sagemath#37856.
This will be fixed in this PR.

More precisely we replace `install_scripts` by appending
`$SAGE_ROOT/local/bin` to the `bash` path variable. This does not affect
Sage but ensures easy access to `gap`,  `maxima`, ... in a `bash`
session (see
sagemath#37856 (comment) ff).

### 📝 Checklist

<!-- Put an `x` in all the boxes that apply. -->

- [x] The title is concise and informative.
- [x] The description explains in detail what this PR is about.
- [x] I have linked a relevant issue or discussion.
- [ ] I have created tests covering the changes.
- [ ] I have updated the documentation and checked the documentation
preview.

### ⌛ Dependencies

<!-- List all open PRs that this PR logically depends on. For example,
-->
<!-- - sagemath#12345: short description why this is a dependency -->
<!-- - sagemath#34567: ... -->

URL: sagemath#38049
Reported by: Sebastian Oehms
Reviewer(s): Matthias Köppe
  • Loading branch information
Release Manager committed May 24, 2024
2 parents c2b63fc + c1407f9 commit 7e76116
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions build/pkgs/configure/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
tarball=configure-VERSION.tar.gz
sha1=dca19f73642b76f1f96b860bb6603499f586380d
sha256=843e060687a9a2360ea3e9499e5c20eb744fcfc2acd4b13c01444ecd961fd43e
sha1=3071e275e8a5582253b9ec5f491744e85c1279a7
sha256=756f05a294aa6effe91300f5f229a4db618952be524fcc6e87f86ceefb84d3ee
2 changes: 1 addition & 1 deletion build/pkgs/configure/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
f5e78840b108412e1e26382910af993f874c6933
c848dbee50babf84a03317d92bcf2aa028bf692d
6 changes: 4 additions & 2 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,10 @@ FROM run-time-dependencies as sagemath
ARG HOME=/home/sage
ARG SAGE_ROOT=/home/sage/sage
COPY --chown=sage:sage --from=make-release $SAGE_ROOT/ $SAGE_ROOT/
# Put scripts to start gap, gp, maxima, ... in /usr/bin
RUN sudo $SAGE_ROOT/sage --nodotsage -c "install_scripts('/usr/bin')"
# set path in bashrc to start gap, gp, maxima, ... this does not
# affect Sage (see https://github.com/sagemath/sage/pull/38049)
RUN echo "export PATH=$SAGE_ROOT/local/bin:$PATH" >> ~/.bashrc

COPY ./docker/entrypoint.sh /usr/local/bin/sage-entrypoint
WORKDIR $HOME
ENTRYPOINT ["/usr/local/bin/sage-entrypoint"]
Expand Down

0 comments on commit 7e76116

Please sign in to comment.