Skip to content

Commit

Permalink
readme changed
Browse files Browse the repository at this point in the history
  • Loading branch information
CyanoFresh committed Aug 17, 2021
1 parent e5214fb commit a550f91
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 2 deletions.
Binary file added .github/build_time.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 21 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,23 @@
Docker Compose + Github Actions + Layers Cache
Docker Compose + GitHub Actions + Layers Cache
===

Example project.
Decrease build time of docker compose inside GitHub Actions using layers cache.

2x faster builds:

![Image of Build time](./.github/build_time.png)

## Description

* `.github/workflows/not-cached.yml` uses `./docker-compose.ci.not-cached.yml`
* `.github/workflows/cached.yml` uses `./docker-compose.yml`. Caching achieved by:
* ENV variables `DOCKER_BUILDKIT` and `COMPOSE_DOCKER_CLI_BUILD`
* docker/setup-buildx-action
* --build-arg BUILDKIT_INLINE_CACHE=1
* `cache_from` inside docker-compose file:
```yml
build:
context: ./app1
cache_from:
- ghcr.io/cyanofresh/docker-compose-ga-cache-example_app1
```

0 comments on commit a550f91

Please sign in to comment.