Fossil SCM
Reordered a few sections in the container customization section to flow better and reduce redundancy.
Commit
bb189d17f248aa3236c735581c1865e38b186fad9ed658a90167b058ab083222
Parent
301d4f21bcd2260…
1 file changed
+20
-28
+20
-28
| --- www/containers.md | ||
| +++ www/containers.md | ||
| @@ -333,12 +333,12 @@ | ||
| 333 | 333 | $ docker create --name fossil-static-tmp fossil |
| 334 | 334 | $ docker cp fossil-static-tmp:/bin/fossil . |
| 335 | 335 | $ docker container rm fossil-static-tmp |
| 336 | 336 | ``` |
| 337 | 337 | |
| 338 | -The resulting binary is the single largest file inside that container, | |
| 339 | -at about 6 MiB. (It’s built stripped.) | |
| 338 | +The result is six or seven megs, depending on the CPU architecture you | |
| 339 | +build for. It’s built stripped. | |
| 340 | 340 | |
| 341 | 341 | [lsl]: https://stackoverflow.com/questions/3430400/linux-static-linking-is-dead |
| 342 | 342 | |
| 343 | 343 | |
| 344 | 344 | ## 5. <a id="custom" name="args"></a>Customization Points |
| @@ -385,44 +385,21 @@ | ||
| 385 | 385 | close to zero as we can manage. |
| 386 | 386 | |
| 387 | 387 | To change it to something else, say: |
| 388 | 388 | |
| 389 | 389 | ``` |
| 390 | - $ make container-image \ | |
| 391 | - DBFLAGS='--build-arg UID=501' | |
| 390 | + $ make container-image DBFLAGS='--build-arg UID=501' | |
| 392 | 391 | ``` |
| 393 | 392 | |
| 394 | 393 | This is particularly useful if you’re putting your repository on a |
| 395 | 394 | separate volume since the IDs “leak” out into the host environment via |
| 396 | 395 | file permissions. You may therefore wish them to mean something on both |
| 397 | 396 | sides of the container barrier rather than have “499” appear on the host |
| 398 | 397 | in “`ls -l`” output. |
| 399 | 398 | |
| 400 | 399 | |
| 401 | -### 5.3 <a id="config"></a>Fossil Configuration Options | |
| 402 | - | |
| 403 | -You can use this same mechanism to enable non-default Fossil | |
| 404 | -configuration options in your build. For instance, to turn on | |
| 405 | -the JSON API and the TH1 docs extension: | |
| 406 | - | |
| 407 | -``` | |
| 408 | - $ make container-image \ | |
| 409 | - DBFLAGS='--build-arg FSLCFG="--json --with-th1-docs"' | |
| 410 | -``` | |
| 411 | - | |
| 412 | -If you also wanted [the Tcl evaluation extension](./th1.md#tclEval), | |
| 413 | -that’s trickier because it requires the `tcl-dev` package to be | |
| 414 | -installed atop Alpine Linux in the first image build stage. We don’t | |
| 415 | -currently have a way to do that because it brings you to a new problem: | |
| 416 | -Alpine provides only a dynamic Tcl library, which conflicts with our | |
| 417 | -wish for [a static Fossil binary](#static). For those who want such a | |
| 418 | -“batteries included” container, we recommend taking a look at [this | |
| 419 | -alternative](https://hub.docker.com/r/duvel/fossil); needless to say, | |
| 420 | -it’s inherently less secure than our stock container, but you may find | |
| 421 | -the tradeoff worthwhile. | |
| 422 | - | |
| 423 | -### 5.4 <a id="cengine"></a>Container Engine | |
| 400 | +### 5.3 <a id="cengine"></a>Container Engine | |
| 424 | 401 | |
| 425 | 402 | Although the Fossil container build system defaults to Docker, we allow |
| 426 | 403 | for use of any OCI container system that implements the same interfaces. |
| 427 | 404 | We go into more details about this in [the next section](#light), but |
| 428 | 405 | for now, it suffices to point out that you can switch to Podman while |
| @@ -431,11 +408,26 @@ | ||
| 431 | 408 | ``` |
| 432 | 409 | $ make CENGINE=podman container-run |
| 433 | 410 | ``` |
| 434 | 411 | |
| 435 | 412 | |
| 436 | -### 5.3 <a id="run"></a>Elaborating the Run Layer | |
| 413 | +### 5.4 <a id="config"></a>Fossil Configuration Options | |
| 414 | + | |
| 415 | +You can use this same mechanism to enable non-default Fossil | |
| 416 | +configuration options in your build. For instance, to turn on | |
| 417 | +the JSON API and the TH1 docs extension: | |
| 418 | + | |
| 419 | +``` | |
| 420 | + $ make container-image \ | |
| 421 | + DBFLAGS='--build-arg FSLCFG="--json --with-th1-docs"' | |
| 422 | +``` | |
| 423 | + | |
| 424 | +If you also wanted [the Tcl evaluation extension](./th1.md#tclEval), | |
| 425 | +that brings us to [the next section](#run). | |
| 426 | + | |
| 427 | + | |
| 428 | +### 5.5 <a id="run"></a>Elaborating the Run Layer | |
| 437 | 429 | |
| 438 | 430 | If you want a basic shell environment for temporary debugging of the |
| 439 | 431 | running container, that’s easily added. Simply change this line in the |
| 440 | 432 | `Dockerfile`… |
| 441 | 433 | |
| 442 | 434 |
| --- www/containers.md | |
| +++ www/containers.md | |
| @@ -333,12 +333,12 @@ | |
| 333 | $ docker create --name fossil-static-tmp fossil |
| 334 | $ docker cp fossil-static-tmp:/bin/fossil . |
| 335 | $ docker container rm fossil-static-tmp |
| 336 | ``` |
| 337 | |
| 338 | The resulting binary is the single largest file inside that container, |
| 339 | at about 6 MiB. (It’s built stripped.) |
| 340 | |
| 341 | [lsl]: https://stackoverflow.com/questions/3430400/linux-static-linking-is-dead |
| 342 | |
| 343 | |
| 344 | ## 5. <a id="custom" name="args"></a>Customization Points |
| @@ -385,44 +385,21 @@ | |
| 385 | close to zero as we can manage. |
| 386 | |
| 387 | To change it to something else, say: |
| 388 | |
| 389 | ``` |
| 390 | $ make container-image \ |
| 391 | DBFLAGS='--build-arg UID=501' |
| 392 | ``` |
| 393 | |
| 394 | This is particularly useful if you’re putting your repository on a |
| 395 | separate volume since the IDs “leak” out into the host environment via |
| 396 | file permissions. You may therefore wish them to mean something on both |
| 397 | sides of the container barrier rather than have “499” appear on the host |
| 398 | in “`ls -l`” output. |
| 399 | |
| 400 | |
| 401 | ### 5.3 <a id="config"></a>Fossil Configuration Options |
| 402 | |
| 403 | You can use this same mechanism to enable non-default Fossil |
| 404 | configuration options in your build. For instance, to turn on |
| 405 | the JSON API and the TH1 docs extension: |
| 406 | |
| 407 | ``` |
| 408 | $ make container-image \ |
| 409 | DBFLAGS='--build-arg FSLCFG="--json --with-th1-docs"' |
| 410 | ``` |
| 411 | |
| 412 | If you also wanted [the Tcl evaluation extension](./th1.md#tclEval), |
| 413 | that’s trickier because it requires the `tcl-dev` package to be |
| 414 | installed atop Alpine Linux in the first image build stage. We don’t |
| 415 | currently have a way to do that because it brings you to a new problem: |
| 416 | Alpine provides only a dynamic Tcl library, which conflicts with our |
| 417 | wish for [a static Fossil binary](#static). For those who want such a |
| 418 | “batteries included” container, we recommend taking a look at [this |
| 419 | alternative](https://hub.docker.com/r/duvel/fossil); needless to say, |
| 420 | it’s inherently less secure than our stock container, but you may find |
| 421 | the tradeoff worthwhile. |
| 422 | |
| 423 | ### 5.4 <a id="cengine"></a>Container Engine |
| 424 | |
| 425 | Although the Fossil container build system defaults to Docker, we allow |
| 426 | for use of any OCI container system that implements the same interfaces. |
| 427 | We go into more details about this in [the next section](#light), but |
| 428 | for now, it suffices to point out that you can switch to Podman while |
| @@ -431,11 +408,26 @@ | |
| 431 | ``` |
| 432 | $ make CENGINE=podman container-run |
| 433 | ``` |
| 434 | |
| 435 | |
| 436 | ### 5.3 <a id="run"></a>Elaborating the Run Layer |
| 437 | |
| 438 | If you want a basic shell environment for temporary debugging of the |
| 439 | running container, that’s easily added. Simply change this line in the |
| 440 | `Dockerfile`… |
| 441 | |
| 442 |
| --- www/containers.md | |
| +++ www/containers.md | |
| @@ -333,12 +333,12 @@ | |
| 333 | $ docker create --name fossil-static-tmp fossil |
| 334 | $ docker cp fossil-static-tmp:/bin/fossil . |
| 335 | $ docker container rm fossil-static-tmp |
| 336 | ``` |
| 337 | |
| 338 | The result is six or seven megs, depending on the CPU architecture you |
| 339 | build for. It’s built stripped. |
| 340 | |
| 341 | [lsl]: https://stackoverflow.com/questions/3430400/linux-static-linking-is-dead |
| 342 | |
| 343 | |
| 344 | ## 5. <a id="custom" name="args"></a>Customization Points |
| @@ -385,44 +385,21 @@ | |
| 385 | close to zero as we can manage. |
| 386 | |
| 387 | To change it to something else, say: |
| 388 | |
| 389 | ``` |
| 390 | $ make container-image DBFLAGS='--build-arg UID=501' |
| 391 | ``` |
| 392 | |
| 393 | This is particularly useful if you’re putting your repository on a |
| 394 | separate volume since the IDs “leak” out into the host environment via |
| 395 | file permissions. You may therefore wish them to mean something on both |
| 396 | sides of the container barrier rather than have “499” appear on the host |
| 397 | in “`ls -l`” output. |
| 398 | |
| 399 | |
| 400 | ### 5.3 <a id="cengine"></a>Container Engine |
| 401 | |
| 402 | Although the Fossil container build system defaults to Docker, we allow |
| 403 | for use of any OCI container system that implements the same interfaces. |
| 404 | We go into more details about this in [the next section](#light), but |
| 405 | for now, it suffices to point out that you can switch to Podman while |
| @@ -431,11 +408,26 @@ | |
| 408 | ``` |
| 409 | $ make CENGINE=podman container-run |
| 410 | ``` |
| 411 | |
| 412 | |
| 413 | ### 5.4 <a id="config"></a>Fossil Configuration Options |
| 414 | |
| 415 | You can use this same mechanism to enable non-default Fossil |
| 416 | configuration options in your build. For instance, to turn on |
| 417 | the JSON API and the TH1 docs extension: |
| 418 | |
| 419 | ``` |
| 420 | $ make container-image \ |
| 421 | DBFLAGS='--build-arg FSLCFG="--json --with-th1-docs"' |
| 422 | ``` |
| 423 | |
| 424 | If you also wanted [the Tcl evaluation extension](./th1.md#tclEval), |
| 425 | that brings us to [the next section](#run). |
| 426 | |
| 427 | |
| 428 | ### 5.5 <a id="run"></a>Elaborating the Run Layer |
| 429 | |
| 430 | If you want a basic shell environment for temporary debugging of the |
| 431 | running container, that’s easily added. Simply change this line in the |
| 432 | `Dockerfile`… |
| 433 | |
| 434 |