Skip to content

Commit

Permalink
chore(build): add e2e to ci workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
jeqo committed Aug 22, 2023
1 parent fc5a7d2 commit 8b268bd
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 5 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,15 @@ jobs:
java-version: 11
distribution: temurin

- name: Read version from properties file
id: read-version
run: |
version=$(grep -oP 'version=\K[^[:space:]]+' gradle.properties)
echo "Version found: $version"
echo "VERSION=$version" >> $GITHUB_ENV
- name: Build with Gradle
run: ./gradlew build
run: make build/distributions/tiered-storage-for-apache-kafka-${{ env.VERSION }}.tgz

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
17 changes: 14 additions & 3 deletions .github/workflows/main_push_and_pull_request_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,24 @@ jobs:
java-version: ${{ matrix.java-version }}
distribution: temurin

- name: Read version from properties file
id: read-version
run: |
version=$(grep -oP 'version=\K[^[:space:]]+' gradle.properties)
echo "Version found: $version"
echo "VERSION=$version" >> $GITHUB_ENV
- name: Build with Gradle
run: ./gradlew build distTar -x integrationTest
run: stdbuf -oL make build/distributions/tiered-storage-for-apache-kafka-${{ env.VERSION }}.tgz

- name: Run integration tests
run: ./gradlew integrationTest
run: stdbuf -oL make integration_test

- name: Build Docker image
run: make docker_image
run: stdbuf -oL make docker_image

- name: Run E2E tests
timeout-minutes: 15
run: make e2e_test

# TODO: publish docker image
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
##

VERSION=0.0.1-SNAPSHOT
IMAGE_TAG=aivenoy/kafka:3.3-2022-10-06-tiered-storage-1-ts-2

Expand All @@ -21,11 +22,14 @@ clean:
./gradlew clean

build/distributions/tiered-storage-for-apache-kafka-$(VERSION).tgz:
./gradlew build distTar -x integrationTest
./gradlew build distTar -x integrationTest -x e2e:test

integration_test: build/distributions/tiered-storage-for-apache-kafka-$(VERSION).tgz
./gradlew integrationTest

e2e_test: build/distributions/tiered-storage-for-apache-kafka-$(VERSION).tgz
./gradlew e2e:test

.PHONY: docker_image
docker_image: build/distributions/tiered-storage-for-apache-kafka-$(VERSION).tgz
docker build . \
Expand Down

0 comments on commit 8b268bd

Please sign in to comment.