77
88env :
99 GO_VERSION : " 1.23.5"
10- REGISTRY_IMAGE : " ghcr.io/proofrock/ws4sql "
10+ REGISTRY_IMAGE : " ghcr.io/proofrock/ws4sql_test "
1111
1212jobs :
1313 test :
4646 - name : Compile and Pack Artifact
4747 run : |
4848 apk add --no-cache musl-dev go g++ git make openssl openssl-dev openssl-libs-static zstd
49- make build-static-linux-musl-amd64
49+ make build-static-ci- linux-musl-amd64
5050 tar czf bin/ws4sql-${{ github.ref_name }}-linux-amd64.tar.gz -C bin/ ws4sql
5151 shell : alpine.sh --root {0}
5252
8080 - name : Compile and Pack Artifact
8181 run : |
8282 apk add --no-cache musl-dev go g++ git make openssl openssl-dev openssl-libs-static zstd
83- make build-static-linux-musl-arm64
83+ make build-static-ci- linux-musl-arm64
8484 tar czf bin/ws4sql-${{ github.ref_name }}-linux-arm64.tar.gz -C bin/ ws4sql
8585 shell : alpine.sh --root {0}
8686
@@ -111,7 +111,7 @@ jobs:
111111
112112 - name : Compile and Pack Artifact
113113 run : |
114- make build
114+ make build-static-macos
115115 tar czf bin/ws4sql-${{ github.ref_name }}-macos-arm64.tar.gz -C bin/ ws4sql
116116 rm bin/ws4sql
117117
@@ -122,6 +122,37 @@ jobs:
122122 path : bin/ws4sql-${{ github.ref_name }}-macos-arm64.tar.gz
123123 retention-days : 1
124124
125+ build_macos_amd64 :
126+ runs-on : macos-13
127+
128+ steps :
129+ - name : Checkout
130+ uses : actions/checkout@v4
131+
132+ - uses : actions/setup-go@v5
133+ with :
134+ go-version : ${{ env.GO_VERSION }}
135+
136+ - name : Modify version number
137+ run : sed -i.bkp 's/v0\.0\.0/${{ github.ref_name }}/g' ws4sql.go
138+ working-directory : src/
139+
140+ - name : Build dir generation
141+ run : mkdir bin/
142+
143+ - name : Compile and Pack Artifact
144+ run : |
145+ make build-static-macos
146+ tar czf bin/ws4sql-${{ github.ref_name }}-macos-amd64.tar.gz -C bin/ ws4sql
147+ rm bin/ws4sql
148+
149+ - name : Upload artifacts
150+ uses : actions/upload-artifact@v4
151+ with :
152+ name : binary_macos_amd64
153+ path : bin/ws4sql-${{ github.ref_name }}-macos-amd64.tar.gz
154+ retention-days : 1
155+
125156 build_win_amd64 :
126157 runs-on : windows-latest
127158
@@ -145,7 +176,7 @@ jobs:
145176
146177 - name : Compile and Pack Artifact
147178 run : |
148- make build-windows
179+ make build-static- windows
149180 zip -j -9 bin/ws4sql-${{ github.ref_name }}-win-amd64.zip bin/ws4sql.exe
150181 rm bin/ws4sql.exe
151182
@@ -236,31 +267,38 @@ jobs:
236267 - build_linux_amd64
237268 - build_linux_arm64
238269 - build_macos_arm64
270+ - build_macos_amd64
239271 - build_win_amd64
240272 - build_docker
241273 - test
242274 runs-on : ubuntu-latest
243275
244276 steps :
245- - name : Download artifacts [1/4 ]
277+ - name : Download artifacts [1/5 ]
246278 uses : actions/download-artifact@v4
247279 with :
248280 name : binary_linux_amd64
249281 path : bin/
250282
251- - name : Download artifacts [2/4 ]
283+ - name : Download artifacts [2/5 ]
252284 uses : actions/download-artifact@v4
253285 with :
254286 name : binary_linux_arm64
255287 path : bin/
256288
257- - name : Download artifacts [3/4 ]
289+ - name : Download artifacts [3/5 ]
258290 uses : actions/download-artifact@v4
259291 with :
260292 name : binary_macos_arm64
261293 path : bin/
262294
263- - name : Download artifacts [4/4]
295+ - name : Download artifacts [4/5]
296+ uses : actions/download-artifact@v4
297+ with :
298+ name : binary_macos_amd64
299+ path : bin/
300+
301+ - name : Download artifacts [5/5]
264302 uses : actions/download-artifact@v4
265303 with :
266304 name : binary_win_amd64
@@ -311,6 +349,16 @@ jobs:
311349 asset_name : ws4sql-${{ github.ref_name }}-macos-arm64.tar.gz
312350 asset_content_type : application/zip
313351
352+ - name : Release Artifact [darwin/amd64]
353+ uses : actions/upload-release-asset@v1
354+ env :
355+ GITHUB_TOKEN : ${{ secrets.TOKEN }}
356+ with :
357+ upload_url : ${{ steps.create_release.outputs.upload_url }}
358+ asset_path : bin/ws4sql-${{ github.ref_name }}-macos-amd64.tar.gz
359+ asset_name : ws4sql-${{ github.ref_name }}-macos-amd64.tar.gz
360+ asset_content_type : application/zip
361+
314362 - name : Release Artifact [windows/amd64]
315363 uses : actions/upload-release-asset@v1
316364 env :
0 commit comments