-
Notifications
You must be signed in to change notification settings - Fork 0
163 lines (142 loc) · 4.26 KB
/
docker-desktop.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
name: docker-desktop
on:
schedule:
- cron: "47 3 * * *"
push:
branches:
- main
paths:
- .github/workflows/docker-desktop.yml
workflow_dispatch:
concurrency:
group: docker-desktop
jobs:
desktop:
name: docker-desktop
runs-on: ubuntu-24.04
permissions:
contents: write
outputs:
version: ${{ steps.fetch.outputs.version }}
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install uniget
uses: uniget-org/uniget-action@main
with:
prefix: helper
tools: gojq
- name: Fetch
id: fetch
run: |
VERSION="$(
curl --silent --show-error --location --fail "https://github.com/docker/docs/raw/main/content/manuals/desktop/release-notes.md" \
| grep '{{< desktop-install all=true' \
| head -n 1 \
| sed -E 's/^.+version="([^"]+)".+$/\1/'
)"
if test -z "${VERSION}"; then
echo "Failed to fetch latest tag and extract version from GitHub"
exit 1
fi
echo "Got version <${VERSION}>"
echo "version=${VERSION}" >>${GITHUB_OUTPUT}
- name: Release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
allowUpdates: true
name: "docker-desktop v${{ steps.fetch.outputs.version }}"
tag: docker-desktop/${{ steps.fetch.outputs.version }}
draft: false
prerelease: false
init:
name: docker-init
needs: desktop
runs-on: ubuntu-24.04
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install uniget
uses: uniget-org/uniget-action@main
with:
prefix: helper
tools: docker-init
- name: Install tool
run: |
docker_desktop_version="${{ needs.desktop.outputs.version }}" bash -x -e ./helper/usr/local/bin/install-docker-init.sh .
- name: Fetch version
id: fetch
run: |
VERSION="$(
./libexec/docker/cli-plugins/docker-init init --version \
| grep ^Version \
| cut -dv -f2
)"
if test -z "${VERSION}"; then
echo "Unable to get version" >&2
exit 1
fi
echo "Got version ${VERSION}"
echo "version=${VERSION}" >>${GITHUB_OUTPUT}
- name: Release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
allowUpdates: true
name: "docker-init v${{ steps.fetch.outputs.version }}"
tag: docker-init/${{ steps.fetch.outputs.version }}
draft: false
prerelease: false
body: |
docker-desktop@${{ needs.desktop.outputs.version }}
debug:
name: docker-debug
needs: desktop
runs-on: ubuntu-24.04
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install uniget
uses: uniget-org/uniget-action@main
with:
prefix: helper
tools: docker-debug
- name: Install tool
run: |
docker_desktop_version="${{ needs.desktop.outputs.version }}" bash -x -e ./helper/usr/local/bin/install-docker-debug.sh .
- name: Fetch version
id: fetch
run: |
VERSION="$(
./libexec/docker/cli-plugins/docker-debug debug --version \
| grep ^Version \
| cut -d' ' -f2
)"
if test -z "${VERSION}"; then
echo "Unable to get version" >&2
exit 1
fi
echo "Got version ${VERSION}"
echo "version=${VERSION}" >>${GITHUB_OUTPUT}
- name: Release
uses: ncipollo/release-action@v1
with:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
allowUpdates: true
name: "docker-debug v${{ steps.fetch.outputs.version }}"
tag: docker-debug/${{ steps.fetch.outputs.version }}
draft: false
prerelease: false
body: |
docker-desktop@${{ needs.desktop.outputs.version }}