Skip to content
This repository was archived by the owner on May 4, 2021. It is now read-only.

Commit d71582a

Browse files
author
Yiran Wang
authored
Update docs and move them to docs/ (#332)
* Update docs and move them to docs * Update docs and move them to docs/ * typo * typo
1 parent c7788a1 commit d71582a

File tree

5 files changed

+14
-10
lines changed

5 files changed

+14
-10
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Some highlights of Makisu:
1212
* Requires no elevated privileges or containerd/Docker daemon, making the build process portable.
1313
* Uses a distributed layer cache to improve performance across a build cluster.
1414
* Provides control over generated layers with a new optional keyword [`#!COMMIT`](#explicit-commit-and-cache), reducing the number of layers in images.
15-
* Is Docker compatible. Note, the Dockerfile parser in Makisu is opinionated in some scenarios. More details can be found [here](lib/parser/dockerfile/README.md).
15+
* Is Docker compatible. Note, the Dockerfile parser in Makisu is opinionated in some scenarios. More details can be found [here](docs/PARSER.md).
1616

1717
Makisu has been in use at Uber since early 2018, building thousands of images every day across 4
1818
different languages. The motivation and mechanism behind it are explained in https://eng.uber.com/makisu/.
@@ -53,7 +53,7 @@ makisu build -t ${TAG} --dest ${TAR_PATH} ${CONTEXT}
5353

5454
# Running Makisu
5555

56-
For a full list of flags, run `makisu build --help` or refer to the README [here](bin/makisu/README.md).
56+
For a full list of flags, run `makisu build --help` or refer to the README [here](docs/COMMAND.md).
5757

5858
## Makisu anywhere
5959

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,17 @@ Flags:
1212
-f, --file string The absolute path to the dockerfile (default "Dockerfile")
1313
-t, --tag string Image tag (required)
1414
--push stringArray Registry to push image to
15+
--replica stringArray Push targets with alternative full image names "<registry>/<repo>:<tag>"
1516
--registry-config string Set build-time variables
1617
--dest string Destination of the image tar
18+
--target string Set the target build stage to build.
1719
--build-arg stringArray Argument to the dockerfile as per the spec of ARG. Format is "--build-arg <arg>=<value>"
1820
--modifyfs Allow makisu to modify files outside of its internal storage dir
1921
--commit string Set to explicit to only commit at steps with '#!COMMIT' annotations; Set to implicit to commit at every ADD/COPY/RUN step (default "implicit")
2022
--blacklist stringArray Makisu will ignore all changes to these locations in the resulting docker images
2123
--local-cache-ttl duration Time-To-Live for local cache (default 168h0m0s)
2224
--redis-cache-addr string The address of a redis server for cacheID to layer sha mapping
23-
--redis-cache-password string The password of the Redis server, should match 'requirepass' in redis.conf
25+
--redis-cache-password string The password of the Redis server, should match 'requirepass' in redis.conf
2426
--redis-cache-ttl duration Time-To-Live for redis cache (default 168h0m0s)
2527
--http-cache-addr string The address of the http server for cacheID to layer sha mapping
2628
--http-cache-header stringArray Request header for http cache server. Format is "--http-cache-header <header>:<value>"
@@ -30,6 +32,7 @@ Flags:
3032
--load Load image into docker daemon after build. Requires access to docker socket at location defined by ${DOCKER_HOST}
3133
--storage string Directory that makisu uses for temp files and cached layers. Mount this path for better caching performance. If modifyfs is set, default to /makisu-storage; Otherwise default to /tmp/makisu-storage
3234
--compression string Image compression level, could be 'no', 'speed', 'size', 'default' (default "default")
35+
--preserve-root Copy / in the storage dir and copy it back after build.
3336
-h, --help help for build
3437
3538
Global Flags:
Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ The following directives are not supported: ONBUILD and SHELL.
2929
Syntax:
3030
- #!COMMIT
3131
- 'COMMIT' can be any case and there can be whitespace preceding '#', after '!', or after 'COMMIT'.
32-
- It cannot be at the beginning of a line, since all lines beginning with '#' would be ignored.
32+
- It cannot be at the beginning of a line, since all lines beginning with '#' would be ignored.
3333

3434
This is a special directive that indicates that a layer should be committed (used in the distributed cache). To enable this directive, `--commit=explicit` argument is required.
3535

@@ -59,12 +59,13 @@ Variables are substituted using values from ARGs and ENVs within the stage.
5959
## COPY
6060

6161
Syntax:
62-
- COPY \[--chown=\<user\>:\<group\>\] \[--from=\<name|index\>\] \<src\> ... \<dest\>
62+
- COPY \[--chown=\<user\>:\<group\>\] \[--from=\<name|index\>\] \[--archive\] \<src\> ... \<dest\>
6363
- Arguments must be separated by whitespace.
64-
- COPY \[--chown=\<user\>:\<group\>\] \[--from=\<name|index\>\] \["\<src\>",... "\<dest\>"\] (this form is required for paths containing whitespace)
64+
- COPY \[--chown=\<user\>:\<group\>\] \[--from=\<name|index\>\] \[--archive\] \["\<src\>",... "\<dest\>"\] (this form is required for paths containing whitespace)
6565
- JSON format.
6666

6767
Variables are substituted using values from ARGs and ENVs within the stage.
68+
`--archive` is a makisu-specific option. By default, makisu will follow docker's behavior, where `dst` itself might be owned by root if not created beforehand. Adding `--archive` will make COPY preserve the original owner and permissions of `src` and its underlying files and directories.
6869

6970
## ENTRYPOINT
7071

docs/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ Some highlights of Makisu:
1212
* Requires no elevated privileges or containerd/Docker daemon, making the build process portable.
1313
* Uses a distributed layer cache to improve performance across a build cluster.
1414
* Provides control over generated layers with a new optional keyword [`#!COMMIT`](#explicit-commit-and-cache), reducing the number of layers in images.
15-
* Is Docker compatible. Note, the Dockerfile parser in Makisu is opinionated in some scenarios. More details can be found [here](lib/parser/dockerfile/README.md).
15+
* Is Docker compatible. Note, the Dockerfile parser in Makisu is opinionated in some scenarios. More details can be found [here](docs/PARSER.md).
1616

1717
Makisu has been in use at Uber since early 2018, building thousands of images every day across 4
1818
different languages. The motivation and mechanism behind it are explained in https://eng.uber.com/makisu/.
@@ -53,7 +53,7 @@ makisu build -t ${TAG} --dest ${TAR_PATH} ${CONTEXT}
5353

5454
# Running Makisu
5555

56-
For a full list of flags, run `makisu build --help` or refer to the README [here](bin/makisu/README.md).
56+
For a full list of flags, run `makisu build --help` or refer to the README [here](docs/COMMAND.md).
5757

5858
## Makisu anywhere
5959

site/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@
178178
* Provides control over generated layers with a new optional keyword <a
179179
href="#explicit-commit-and-cache"><code>#!COMMIT</code></a>, reducing the number of layers in images.
180180
* Is Docker compatible. Note, the Dockerfile parser in Makisu is opinionated in some scenarios. More
181-
details can be found <a href="lib/parser/dockerfile/README.md">here</a>.</p>
181+
details can be found <a href="docs/PARSER.md">here</a>.</p>
182182
<p>Makisu has been in use at Uber since early 2018, building thousands of images every day across 4
183183
different languages. The motivation and mechanism behind it are explained in
184184
https://eng.uber.com/makisu/.</p>
@@ -214,7 +214,7 @@ <h2 id="building-makisu-binary-and-build-simple-images">Building Makisu binary a
214214

215215
<h1 id="running-makisu">Running Makisu</h1>
216216
<p>For a full list of flags, run <code>makisu build --help</code> or refer to the README <a
217-
href="bin/makisu/README.md">here</a>.</p>
217+
href="docs/COMMAND.md">here</a>.</p>
218218
<h2 id="makisu-anywhere">Makisu anywhere</h2>
219219
<p>To build Dockerfiles that contain RUN, Makisu needs to run in a container.
220220
To try it locally, the following snippet can be placed inside your <code>~/.bashrc</code> or

0 commit comments

Comments
 (0)