Skip to content

Support local and remote build cache #2371

Closed

Description

@waruqi

Is your feature request related to a problem? Please describe.

Local cache

It will be enabled by default.

see #2361

disable cache

$ xmake f --ccache=n
$ xmake

Remote cache

Add configuration

$ cat ~/.xmake/service/server.conf
{
    remote_cache = {
        listen = "0.0.0.0:9692",
        workdir = "/Users/ruki/.xmake/service/server/remote_cache"
    },
    tokens = {
        "caefa7cf0a036e2364fa349dc39b4127"
    }
}
$ cat ~/.xmake/service/client.conf
{
    remote_cache = {
        connect = "127.0.0.1:9692",
        token = "caefa7cf0a036e2364fa349dc39b4127"
    }
}

Start remote server

$ xmake service -vD
<remote_cache_server>: listening 0.0.0.0:9692 ..

Connect remote cache server

$ xmake service --connect --cache
<remote_cache_client>: connect 127.0.0.1:9692 ..
<remote_cache_client>: connected!

Build project with local/remote cache

$ xmake
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions