@@ -25,7 +25,7 @@ and build time (taking advantage of buildx cache).
2525## Requirements
2626
2727- [x] [ docker-engine] ( https://docs.docker.com/get-docker ) >= 20.10.0
28- - [x] docker- compose >= 1.29.0
28+ - [x] docker compose >= 1.29.0
2929- [x] docker [ buildkit] ( https://docs.docker.com/develop/develop-images/build_enhancements ) enabled.
3030- [x] optional: [ lazydocker] ( https://github.com/jesseduffield/lazydocker ) , a beautiful tui.
3131- [x] optional: [ dive] ( https://github.com/wagoodman/dive ) to debug layer sizes.
@@ -50,14 +50,14 @@ and build time (taking advantage of buildx cache).
5050yarn docker:hobbies:develop
5151
5252# Or alternatively
53- DOCKER_BUILDKIT=1 docker- compose -f ./docker-compose.yml -f ./docker-compose.hobbies.yml up develop
53+ DOCKER_BUILDKIT=1 docker compose -f ./docker-compose.yml -f ./docker-compose.hobbies.yml up develop
5454```
5555
5656<details >
5757 <summary >Want to open a shell to debug ?</summary >
5858
5959 ``` bash
60- DOCKER_BUILDKIT=1 docker- compose -f ./docker-compose.hobbies.yml run --rm develop sh
60+ DOCKER_BUILDKIT=1 docker compose -f ./docker-compose.hobbies.yml run --rm develop sh
6161 ```
6262
6363</details >
@@ -84,20 +84,20 @@ stages.
8484 To build it independently
8585
8686 ``` bash
87- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --progress=tty deps
87+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --progress=tty deps
8888 # docker buildx bake -f docker-compose.hobbies.yml --progress=tty deps
8989 ```
9090
9191 To force a rebuild
9292
9393 ``` bash
94- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty deps
94+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty deps
9595 ```
9696
9797 Want to open a shell into it ?
9898
9999 ``` bash
100- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml run --rm deps sh
100+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml run --rm deps sh
101101 ```
102102
103103</details >
@@ -114,20 +114,20 @@ Then build the thing and remove devDependencies.
114114 To build it independently
115115
116116 ``` bash
117- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --progress=tty builder
117+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --progress=tty builder
118118 # docker buildx bake -f docker-compose.hobbies.yml --progress=tty builder
119119 ```
120120
121121 To force a rebuild
122122
123123 ``` bash
124- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty builder
124+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty builder
125125 ```
126126
127127 Want to open a shell into it ?
128128
129129 ``` bash
130- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml run --rm builder sh
130+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml run --rm builder sh
131131 ```
132132
133133</details >
@@ -137,7 +137,7 @@ Then build the thing and remove devDependencies.
137137Launch a production build and listen by default to http://localhost:3000 .
138138
139139``` bash
140- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml --env-file .env.secret up runner
140+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml --env-file .env.secret up runner
141141```
142142
143143> PS: you'll have to provide your own .env with required runtime variables.
@@ -147,20 +147,20 @@ DOCKER_BUILDKIT=1 docker-compose -f docker-compose.hobbies.yml --env-file .env.s
147147 To build it independently
148148
149149 ``` bash
150- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --progress=tty runner
150+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --progress=tty runner
151151 # docker buildx bake -f docker-compose.hobbies.yml --progress=tty runner
152152 ```
153153
154154 To force a rebuild
155155
156156 ``` bash
157- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty runner
157+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml build --no-cache --force-rm --progress=tty runner
158158 ```
159159
160160 Want to open a shell into it ?
161161
162162 ``` bash
163- DOCKER_BUILDKIT=1 docker- compose -f docker-compose.hobbies.yml run --rm runner sh
163+ DOCKER_BUILDKIT=1 docker compose -f docker-compose.hobbies.yml run --rm runner sh
164164 ```
165165
166166</details >
@@ -181,13 +181,13 @@ Using the Sports-Helsinki app as an example.
181181Build the cache-image (for the Sports-Helsinki app):
182182
183183```
184- docker- compose -f docker-compose.sports.yml --env-file ./apps/sports-helsinki/.env.local build cache
184+ docker compose -f docker-compose.sports.yml --env-file ./apps/sports-helsinki/.env.local build cache
185185```
186186
187187Build the app runner image (for the Sports-Helsinki app) by using the cache-image as a base image:
188188
189189```
190- BUILDER_FROM_IMAGE=events-helsinki-monorepo-cache:latest docker- compose -f docker-compose.sports.yml --env-file ./apps/sports-helsinki/.env.local build runner
190+ BUILDER_FROM_IMAGE=events-helsinki-monorepo-cache:latest docker compose -f docker-compose.sports.yml --env-file ./apps/sports-helsinki/.env.local build runner
191191```
192192
193193## Remove docker
0 commit comments