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

Docker for daily development #5991

Open
breezewish opened this issue Sep 22, 2022 · 3 comments
Open

Docker for daily development #5991

breezewish opened this issue Sep 22, 2022 · 3 comments
Labels
type/enhancement The issue or PR belongs to an enhancement.

Comments

@breezewish
Copy link
Member

breezewish commented Sep 22, 2022

Enhancement

Currently we have Docker image in release-centos7-llvm. It is used to build release distributions.

It can be used as the compiler toolchain in daily development, so that developers don't need to carefully configure compiler toolchains by their own.

We can make the following improvements to make it more developer friendly:

  1. Keep compile unit cache by default. Use different build directories for different build types.
  2. Keep Cargo cache and Rust toolchain cache, so that dependencies don't need to be downloaded again and again.
  3. Respond correctly to Ctrl+C.
  4. Optional: Shrink the image size for easier hub downloading.

By using the Docker as the daily development toolchain, it will be also easier to upgrade the LLVM toolchain, without worrying about different developers have different OS that may not be able to install the toolchain.

Related:

@breezewish breezewish added the type/enhancement The issue or PR belongs to an enhancement. label Sep 22, 2022
@iosmanthus
Copy link
Contributor

It's too complicated for the user that just wants to build an image. Should we add a target to make it more simple to build? BTW, there are no docs about how to build a tiflash docker image. 😢

@breezewish
Copy link
Member Author

It's too complicated for the user that just wants to build an image. Should we add a target to make it more simple to build? BTW, there are no docs about how to build a tiflash docker image. 😢

This issue isn't talking about how to build a TiFlash image. It is about how to build a TiFlash binary easier. One of the approach would be using containers.

@breezewish breezewish mentioned this issue Oct 11, 2022
21 tasks
@breezewish
Copy link
Member Author

breezewish commented Oct 11, 2022

Hi 👋

I made an experimental (very early-bird!) image for daily development recent days. Feel free to have a try! I would like to receive your voice and suggestions:

#6112

Note: for now, only x86_64 image is provided, which means, you can only use this image in these ways:

A. You have a local x86_64 environment, in Mac or in Linux. Start a Docker locally using this Image. (Note that Docker in MacOS always starts a VM, so there will be some performance lost).

B. You have a remote x86_64 environment, in Linux. You may run VsCode locally using the Remote Development extension to run Docker on that host, or manually SSH to that host and invoke Docker.

C. Unsupported: You have a local Arm64 environment (M1) and you want to run Docker locally -- Binary translation is super slow, just don't do this for now.


As this image is very clean, it may be even possible to use as the base image for release. In this way, we don't need to maintain many different Docker bake scripts any more.

@breezewish breezewish mentioned this issue Mar 18, 2023
21 tasks
ti-chi-bot pushed a commit that referenced this issue Mar 18, 2023
breezewish added a commit to breezewish/tiflash that referenced this issue Apr 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement The issue or PR belongs to an enhancement.
Projects
None yet
Development

No branches or pull requests

2 participants