Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test artifact transfer #1496

Closed
wants to merge 14 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 7 additions & 46 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,50 +15,11 @@ jobs:

steps:
- uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build with Gradle
run: |
./gradlew clean
git clean -fd
./gradlew build

- name: Fail if slf4j is found in the log
if: matrix.os == 'ubuntu-latest'
- name: Fetch artifact from another repository
run: |
set +e
java -jar application/build/libs/specmatic.jar --version 2>&1 | grep -i slf4j

if [ $? -eq 0 ]
then
exit 1
fi

- name: Upload core Gradle Log
if: always()
uses: actions/upload-artifact@v4
with:
name: Gradle core build Log on ${{ matrix.os }}
path: core/build/reports/

- name: Upload junit5-support Gradle Log
if: always()
uses: actions/upload-artifact@v4
with:
name: Gradle junit5-support build Log on ${{ matrix.os }}
path: junit5-support/build/reports/

- name: Upload application Gradle Log
if: always()
uses: actions/upload-artifact@v4
with:
name: Gradle application build Log on ${{ matrix.os }}
path: application/build/reports/
curl -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/znsio/example-inline-editor-module/actions/artifacts \
| jq '.artifacts[0].archive_download_url' \
| xargs curl -L -o artifact.zip
unzip artifact.zip -d ./downloaded-artifact/
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ RUN apk update && \

# Copy the Specmatic JAR file into the container
COPY ./application/build/libs/specmatic.jar /usr/src/app/specmatic.jar

COPY ./TMF621-Trouble_Ticket-v5.0.0.oas.yaml /usr/src/app/TMF621-Trouble_Ticket-v5.0.0.oas.yaml
# Set the entrypoint to run the Specmatic JAR
ENTRYPOINT ["java", "-jar", "/usr/src/app/specmatic.jar"]
CMD ["examples", "interactive", "--contract-file=TMF621-Trouble_Ticket-v5.0.0.oas.yaml"]

Loading
Loading