Skip to content

Commit ae90ebe

Browse files
Merge pull request #764 from cybozu-go/docker-compose-v2
use docker compose v2 in appropriate way
2 parents e36b228 + ec95c1a commit ae90ebe

File tree

5 files changed

+14
-13
lines changed

5 files changed

+14
-13
lines changed

.github/workflows/main.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -115,13 +115,13 @@ jobs:
115115
working-directory: ./example
116116
- name: Set up compose test
117117
run: |
118-
docker-compose build
119-
docker-compose up -d
118+
docker compose build
119+
docker compose up -d
120120
./wait-up.sh
121121
working-directory: ./example
122122
- name: Run compose test
123-
run: docker-compose run setup /opt/setup/test.sh
123+
run: docker compose run setup /opt/setup/test.sh
124124
working-directory: ./example
125125
- name: Clean up
126-
run: docker-compose down
126+
run: docker compose down
127127
working-directory: ./example

RELEASE.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ GitHub Actions also creates a GitHub release automatically after running [sonobu
8080
So, **DO NOT MANUALLY CREATE GITHUB RELEASES**. The test results will be attached to the GitHub
8181
release that can be submitted to [cncf/k8s-conformance](https://github.com/cncf/k8s-conformance).
8282

83-
## Maintain docker-compose
83+
## Maintain docker compose
8484

8585
After new CKE released, update cke image on docker-compose.yml.
8686

example/README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Demonstration with docker-compose and Vagrant
1+
# Demonstration with `docker compose` and Vagrant
22

33
## Overview
44

@@ -19,14 +19,14 @@ Use this only for testing and development.
1919

2020
## Setup CKE
2121

22-
Follow the steps to setup CKE with docker-compose.
22+
Follow the steps to setup CKE with `docker compose`.
2323

2424
```console
2525
$ git clone https://github.com/cybozu-go/cke.git
2626
$ cd ./cke/example/
2727
$ mkdir bin
2828
$ mkdir etcd-data
29-
$ docker-compose up -d
29+
$ docker compose up -d
3030
```
3131

3232
`bin` is the directory where the cli tools are installed.

sonobuoy/Makefile

+5-4
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ bin/sonobuoy:
4444
.PHONY: run
4545
run: bin/cke bin/ckecli bin/kubectl
4646
mkdir -p etcd-data
47-
/usr/local/bin/docker-compose up -d
47+
docker compose up -d
4848
./wait-up.sh
4949
$(CKECLI) vault ssh-privkey /home/cybozu/gcp_rsa
5050
$(CKECLI) constraints set minimum-workers 2
@@ -66,13 +66,14 @@ sonobuoy: bin/sonobuoy
6666

6767
.PHONY: clean
6868
clean:
69-
-/usr/local/bin/docker-compose down
69+
-docker compose down
7070
$(SUDO) rm -rf bin etcd-data
7171

7272
.PHONY: setup
7373
setup:
74-
$(SUDO) $(CURL) -o /usr/local/bin/docker-compose $(DOCKER_COMPOSE_URL)
75-
$(SUDO) chmod +x /usr/local/bin/docker-compose
74+
$(SUDO) mkdir -p /usr/local/lib/docker/cli-plugins
75+
$(SUDO) $(CURL) -o /usr/local/lib/docker/cli-plugins/docker-compose $(DOCKER_COMPOSE_URL)
76+
$(SUDO) chmod +x /usr/local/lib/docker/cli-plugins/docker-compose
7677

7778
$(CT):
7879
mkdir -p bin

sonobuoy/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ [email protected]
3535
## Run Sonobuoy
3636

3737
Run `bin/run-sonobuoy.sh`.
38-
This script creates 4 GCE VMs, runs CKE on VM #0 by using `docker-compose`, runs Kubernetes deployed by CKE on VM #1~#3, and runs [Sonobuoy][] on VM #0.
38+
This script creates 4 GCE VMs, runs CKE on VM #0 by using `docker compose`, runs Kubernetes deployed by CKE on VM #1~#3, and runs [Sonobuoy][] on VM #0.
3939

4040
```console
4141
$ env INSTANCE_NAME=sonobuoy-vm GITHUB_SHA=vX.Y.Z GITHUB_REPOSITORY=cybozu-go/cke ./bin/run-sonobuoy.sh

0 commit comments

Comments
 (0)