Skip to content
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

build: tidy dockerfile #1477

Merged
merged 1 commit into from
May 27, 2023
Merged

build: tidy dockerfile #1477

merged 1 commit into from
May 27, 2023

Conversation

tisonkun
Copy link
Member

Comments inline.

compactdb
testdb

build
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add .gitignore content. Avoid build content conflict issues.

@@ -19,10 +19,6 @@ FROM alpine:3.16 as build

ARG MORE_BUILD_ARGS

# workaround tzdata install hanging
ENV TZ=Etc/UTC
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After switching to Alpine, we don't need this trick.

VOLUME /var/lib/kvrocks

RUN chown kvrocks:kvrocks /var/lib/kvrocks
COPY --from=build /kvrocks/build/kvrocks /bin/
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simplify a bit layout:

/bin/kvrocks
/bin/redis-cli
/kvrocks/<LICENSE/NOTICE>
/var/...

VOLUME /var/lib/kvrocks

RUN chown kvrocks:kvrocks /var/lib/kvrocks
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicated above.

@tisonkun
Copy link
Member Author

cc @aleksraiden may you verify this patch also.

@tisonkun tisonkun requested a review from git-hulk May 27, 2023 17:31
@aleksraiden
Copy link
Contributor

cc @aleksraiden may you verify this patch also.

Awesome! LGTM

@tisonkun
Copy link
Member Author

Merging...

Thanks for your review!

@tisonkun tisonkun merged commit bb8c3c2 into apache:unstable May 27, 2023
@tisonkun tisonkun deleted the dockerbuild branch May 27, 2023 23:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants