Skip to content

Commit 0fc957b

Browse files
committed
feat: install docker buildx plugin
1 parent 7075d14 commit 0fc957b

File tree

3 files changed

+16
-6
lines changed

3 files changed

+16
-6
lines changed

.github/workflows/test.yaml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,13 @@ on:
88
branches:
99
- main
1010
schedule:
11-
- cron: "0 7 * * *"
11+
- cron: "0 5 * * *"
12+
workflow_dispatch:
13+
inputs:
14+
15+
concurrency:
16+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
17+
cancel-in-progress: true
1218

1319
jobs:
1420

kind.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,9 @@ install_kubectl() {
173173
install_docker() {
174174
if [ "$RUNNER_OS" == "macOS" ] && ! [ -x "$(command -v docker)" ]; then
175175
echo 'Installing docker...'
176-
brew install docker colima
176+
brew install docker docker-buildx colima
177+
mkdir -p ~/.docker/cli-plugins
178+
ln -sfn /usr/local/opt/docker-buildx/bin/docker-buildx ~/.docker/cli-plugins/docker-buildx
177179
colima start
178180
fi
179181
}

registry.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ main() {
5454
local document=false
5555

5656
parse_command_line "$@"
57-
57+
5858
if [[ "$document" = "false" ]]
5959
then
6060
install_docker
@@ -176,8 +176,10 @@ parse_command_line() {
176176
install_docker() {
177177
if [ "$RUNNER_OS" == "macOS" ] && ! [ -x "$(command -v docker)" ]; then
178178
echo 'Installing docker...'
179-
brew install docker colima
180-
colima start --cpu "$cpu" --memory "$memory" --disk "$disk"
179+
brew install docker docker-buildx colima
180+
mkdir -p ~/.docker/cli-plugins
181+
ln -sfn /usr/local/opt/docker-buildx/bin/docker-buildx ~/.docker/cli-plugins/docker-buildx
182+
colima start
181183
fi
182184
}
183185

@@ -201,7 +203,7 @@ connect_registry() {
201203

202204
create_kind_config() {
203205
sudo mkdir -p /etc/kind-registry
204-
cat <<EOF | sudo dd status=none of=/etc/kind-registry/config.yaml
206+
cat <<EOF | sudo dd of=/etc/kind-registry/config.yaml
205207
kind: Cluster
206208
apiVersion: kind.x-k8s.io/v1alpha4
207209
containerdConfigPatches:

0 commit comments

Comments
 (0)