Skip to content

Commit

Permalink
Merge pull request #410 from Enmk/relase-artifacts-final
Browse files Browse the repository at this point in the history
Uploading release artifacts
  • Loading branch information
Enmk authored Sep 9, 2022
2 parents a49858e + 6285aa0 commit fab6efc
Show file tree
Hide file tree
Showing 5 changed files with 71 additions and 7 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/Docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,27 @@ jobs:
run: |
docker run --entrypoint /bin/bash -v $(realpath ${{ github.workspace }}/packages):/packages clickhouse_odbc_tester:${{ matrix.odbc_provider }}-${{ matrix.base_os }} -c 'cd clickhouse-odbc-build && ls -lah && ninja package ||: ; mv clickhouse-odbc-* /packages && ls -lah /packages'
- name: List artifacts
run: |
echo REF: ${{ github.ref }}
ls -lahR ${{ github.workspace }}/packages/
- name: Upload the artifacts
uses: actions/upload-artifact@v3
with:
name: clickhouse-odbc-${{ matrix.base_os }}-${{ matrix.odbc_provider }}
path: ${{ github.workspace }}/packages/*tar.gz*

- name: Upload artifacts as release assets
if: ${{ github.event_name == 'release' }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ${{ github.workspace }}/packages/clickhouse-odbc-*
overwrite: true
tag: ${{ github.ref }}
file_glob: true

# - name: Test - Run unit tests
# run: docker run --network=host clickhouse_odbc_tester:${{ matrix.odbc_provider }} -R '.*-ut.*'

Expand Down
14 changes: 11 additions & 3 deletions .github/workflows/Linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,19 @@ jobs:
- name: Package
run: cmake --build ${{ github.workspace }}/build --config ${{ matrix.build_type }} --target package

- name: List artifacts
run: |
echo REF: ${{ github.ref }}
ls -lahR ${{ github.workspace }}/build/
# Linux release artifacts are uploaded in Docker.yml
# That builds binaries based on CentOS 7, which makes those more portable.
# However, these binaries are uploaded to be available in GH's 'Actions', just in case.
- name: Upload the artifacts
if: ${{ matrix.os == 'ubuntu-18.04' && matrix.compiler == 'GCC' && matrix.odbc_provider == 'UnixODBC' && matrix.build_type == 'Release' && matrix.runtime_link == 'dynamic-runtime' && matrix.third_parties == 'bundled-third-parties' }}
if: ${{ matrix.compiler == 'GCC' && matrix.odbc_provider == 'UnixODBC' && matrix.build_type == 'Release' && matrix.runtime_link == 'dynamic-runtime' && matrix.third_parties == 'bundled-third-parties' }}
uses: actions/upload-artifact@v3
with:
name: clickhouse-odbc-linux
name: clickhouse-odbc-linux-${{ matrix.compiler }}-${{ matrix.odbc_provider }}-${{ matrix.build_type }}
path: ${{ github.workspace }}/build/clickhouse-odbc-*

- name: Test - Run unit tests
Expand Down Expand Up @@ -214,4 +222,4 @@ jobs:
fi
# Run all tests except those that were run in "Test - unit tests" step.
ctest --output-on-failure --build-config ${{ matrix.build_type }} -E '.*-ut.*'
ctest --output-on-failure --build-config ${{ matrix.build_type }} -E '.*-ut.*'
19 changes: 17 additions & 2 deletions .github/workflows/Windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,16 @@ jobs:
- name: Package
run: cmake --build ${{ github.workspace }}/build --config ${{ matrix.build_type }} --target package

- name: List artifacts
run: |
echo REF: ${{ github.ref }}
dir ${{ github.workspace }}/build
- name: Upload the artifacts
if: ${{ matrix.os == 'windows-2016' && matrix.build_type == 'Release' }}
# if: ${{ matrix.os == 'windows-2019' && matrix.build_type == 'Release' }}
uses: actions/upload-artifact@v3
with:
name: clickhouse-odbc-windows
name: clickhouse-odbc-windows-${{ matrix.architecture }}-${{ matrix.build_type }}
path: ${{ github.workspace }}/build/clickhouse-odbc-*

- name: Test - Run unit tests
Expand Down Expand Up @@ -180,3 +185,13 @@ jobs:

# # Run all tests except those that were run in "Test - unit tests" step.
# ctest --output-on-failure --build-config ${{ matrix.build_type }} -E '.*-ut.*'

- name: Upload artifacts as release assets
if: ${{ github.event_name == 'release' && matrix.build_type == 'Release' }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ${{ github.workspace }}/build/clickhouse-odbc-*
overwrite: true
tag: ${{ github.ref }}
file_glob: true
11 changes: 11 additions & 0 deletions .github/workflows/debug.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Log all debug info to facilitate debugging
name: debug

'on':
[push, pull_request, release]

jobs:
DebugInfo:
runs-on: ubuntu-latest
steps:
- uses: hmarr/[email protected]
19 changes: 17 additions & 2 deletions .github/workflows/macOS.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,16 @@ jobs:
- name: Package
run: cmake --build ${{ github.workspace }}/build --config ${{ matrix.build_type }} --target package

- name: List artifacts
run: |
echo REF: ${{ github.ref }}
ls -lahR ${{ github.workspace }}/build
- name: Upload the artifacts
if: ${{ matrix.compiler == 'AppleClang' && matrix.odbc_provider == 'iODBC' && matrix.build_type == 'Release' }}
# if: ${{ matrix.compiler == 'AppleClang' && matrix.odbc_provider == 'iODBC' && matrix.build_type == 'Release' }}
uses: actions/upload-artifact@v3
with:
name: clickhouse-odbc-macos
name: clickhouse-odbc-macos-${{ matrix.compiler }}-${{ matrix.odbc_provider }}-${{ matrix.build_type }}
path: ${{ github.workspace }}/build/clickhouse-odbc-*

- name: Test - Run unit tests
Expand Down Expand Up @@ -205,3 +210,13 @@ jobs:

# # Run all tests except those that were run in "Test - unit tests" step.
# ctest --output-on-failure --build-config ${{ matrix.build_type }} -E '.*-ut.*'

- name: Upload artifacts as release assets
if: ${{ github.event_name == 'release' && matrix.build_type == 'Release' }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ${{ github.workspace }}/build/clickhouse-odbc-*
overwrite: true
tag: ${{ github.ref }}
file_glob: true

0 comments on commit fab6efc

Please sign in to comment.