-
Notifications
You must be signed in to change notification settings - Fork 96
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
misc: fix 404 for snapshotter dockerfile #312
Conversation
Yes, that is right. The version in a null value.
|
52b68e1
to
e939cde
Compare
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.
This needs to support arm64
Do you mean that we should add a variable to control the architecture?
|
Yes, add add ARG TARGETARCH environment variable |
e939cde
to
ff33bad
Compare
Done. PTAL @fengshunli |
519d68f
to
9ed4474
Compare
refer to ARG TARGETARCH way to achieve |
b893591
to
0f7c3de
Compare
Fixed. |
0f7c3de
to
0a1ad22
Compare
LGTM |
It may be better to add a |
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.
I am wondering why NYDUS_VERSION
is empty.
Agree. It might be because nydus-snapshotter is under Containerd org where a lot of tests are running at the same time |
misc/snapshotter/Dockerfile
Outdated
wget https://github.com/dragonflyoss/image-service/releases/download/$NYDUS_VERSION/nydus-static-$NYDUS_VERSION-linux-amd64.tgz && \ | ||
RUN unset NYDUS_VERSION && \ | ||
while [ -z $NYDUS_VERSION ]; do \ | ||
export NYDUS_VERSION=$(curl --silent "https://api.github.com/repos/dragonflyoss/image-service/releases/latest" | grep -Po '"tag_name": "\K.*?(?=")'); sleep 1; \ |
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.
It's better to limit the total retry times.
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.
Done.
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.
It still failed when i retry 1200 times. Maybe we could assume it will work eventually?
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.
It works now. 10 minutes are enough.
misc/snapshotter/Dockerfile
Outdated
export NYDUS_VERSION=$(curl --silent "https://api.github.com/repos/dragonflyoss/image-service/releases/latest" | grep -Po '"tag_name": "\K.*?(?=")'); sleep 1; \ | ||
done && \ | ||
echo NYDUS_VERSION: $NYDUS_VERSION && \ | ||
if [ -z $NYDUS_VERSION ]; then echo Invalid NYDUS_VERSION && exit -1; fi && \ |
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.
This condition judgment conflicts with line 8, which means the loop should not end.
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.
Yes. Now, we limit the total retry times, so we still need this.
misc/snapshotter/Dockerfile
Outdated
echo NYDUS_VERSION: $NYDUS_VERSION && \ | ||
if [ -z $NYDUS_VERSION ]; then echo Invalid NYDUS_VERSION && exit -1; fi && \ | ||
echo TARGETARCH: $TARGETARCH && \ | ||
if [ "$TARGETARCH" != "amd64" -a "$TARGETARCH" != "arm64" -a "$TARGETARCH" != "ppc64le" -a "$TARGETARCH" != "riscv64" ]; then echo Unsupported TARGETARCH for nydus && exit -1; fi && \ |
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.
I still incline to simplify the test by assuming that only amd64 is the base nydus artifacts platform since the test target platform is decided and can't changed
3506ccc
to
e8c152d
Compare
Dockerfile with |
09b8e02
to
c3d0977
Compare
Codecov ReportBase: 31.55% // Head: 31.55% // No change to project coverage 👍
Additional details and impacted files@@ Coverage Diff @@
## main #312 +/- ##
=======================================
Coverage 31.55% 31.55%
=======================================
Files 34 34
Lines 3578 3578
=======================================
Hits 1129 1129
Misses 2333 2333
Partials 116 116 Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
d318cd3
to
04e9ca2
Compare
Signed-off-by: Bin Tang <tangbin.bin@bytedance.com>
04e9ca2
to
af5d85d
Compare
Agree. |
Thanks for investigating this 👍 |
The github workflow frequently causes errors to break tests:
I guess the reason for this situation is the
$NYDUS_VERSION
is an invalid value.This PR tries to verify it by adding an
echo
command.Signed-off-by: Bin Tang tangbin.bin@bytedance.com