Skip to content

Commit c1ad782

Browse files
committed
Add build workflow
1 parent d903378 commit c1ad782

File tree

2 files changed

+37
-0
lines changed

2 files changed

+37
-0
lines changed

.github/workflows/main.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,7 @@ on:
1212
jobs:
1313
lint:
1414
uses: ./.github/workflows/reusable-lint.yml
15+
build:
16+
uses: ./.github/workflows/reusable-build.yml
17+
with:
18+
version: ${{ github.run_number }}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Build Binary
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
version:
7+
type: string
8+
required: true
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v6
15+
- name: Set up Go
16+
uses: actions/setup-go@v6
17+
with:
18+
go-version-file: go.mod
19+
cache-dependency-path: go.sum
20+
- name: Build
21+
run: |
22+
scripts/build.sh build/dstack-sshproxy ${{ inputs.version }}
23+
- id: upload
24+
uses: actions/upload-artifact@v7
25+
with:
26+
name: dstack-sshproxy
27+
path: build/dstack-sshproxy
28+
retention-days: 1
29+
- name: Report
30+
run: |
31+
echo 'version: ${{ inputs.version }}'
32+
echo 'url: ${{ steps.upload.outputs.artifact-url }}'
33+
echo 'digest: ${{ steps.upload.outputs.artifact-digest }}'

0 commit comments

Comments
 (0)