-
Notifications
You must be signed in to change notification settings - Fork 87
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
WIP: Speed up build #2041
base: master
Are you sure you want to change the base?
WIP: Speed up build #2041
Conversation
RUN git clone --no-checkout https://github.com/CSCfi/csc-user-guide git_folder && \ | ||
if [ -d ".git" ]; then rm -r .git; fi && \ | ||
mv git_folder/.git . && \ | ||
rm -r git_folder && \ | ||
git reset HEAD --hard && \ |
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.
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.
Which is not present in the build done by Rahti BC. Keep in mind that the preview and the production are very different processes.
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.
🤔 the git log says that the page was modified March 7 2023.
The Last update seems to be the same on the feature branch as well as master:
https://csc-guide-preview.rahtiapp.fi/origin/testing-speedup/cloud/
https://docs.csc.fi/cloud/
There is of course something that I still might be missing.
I'm also wondering that IF it is still needed maybe it would be possible to use ADD --keep-git-dir=true
instead of COPY . /tmp
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.
In a Build config OpenShift clones the code automatically but removes the .git
directory before starting to run Dockerfile
. I can prepare a demo example later today/tomorrow.
Proposed changes
Checklist before requesting a review