Skip to content

Commit

Permalink
Should fix release (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
mrhamburg authored Dec 9, 2021
1 parent b89aa13 commit 4d88421
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#TODO: version is not working
# error: Source parameter was not specified.
# see: https://github.com/mrhamburg/airbyte.cdk.dotnet/runs/4473155151?check_suite_focus=true
name: Release Dotnet CDK
on:
release:
Expand All @@ -20,6 +23,6 @@ jobs:
push: false
tags: local/dotnet-cdk:latest
context: .
env:
NUGET_APIKEY: ${{ secrets.NUGET_APIKEY }}
BUILD_VERSION: ${{ github.event.release.tag_name }}
build-args:
NUGET_APIKEY: ${{ secrets.NUGET_APIKEY }}
BUILD_VERSION: ${{ github.event.release.tag_name }}
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Build and publish cdk
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build

ENV BUILD_VERSION="0.0.1"
ENV WORKDIR=/airbyte/build
ARG BUILD_VERSION="0.0.1"
ARG WORKDIR=/airbyte/build
WORKDIR $WORKDIR

COPY . ./
Expand All @@ -13,10 +13,10 @@ WORKDIR $WORKDIR/Airbyte.Cdk
RUN dotnet build -c Release -p:Version=$BUILD_VERSION -o output

FROM build AS publish
ENV NUGET_APIKEY=""
ENV NUGET_SOURCE="https://api.nuget.org/v3/index.json"
ARG NUGET_APIKEY=""
ARG NUGET_SOURCE="https://api.nuget.org/v3/index.json"

ENV WORKDIR=/airbyte/integration_code
ARG WORKDIR=/airbyte/integration_code
WORKDIR $WORKDIR
COPY --from=build /airbyte/build/Airbyte.Cdk/output .
RUN dotnet nuget push ./Airbyte.Cdk.$BUILD_VERSION.nupkg --api-key $NUGET_APIKEY --source $NUGET_SOURCE

0 comments on commit 4d88421

Please sign in to comment.