Skip to content

Merge pull request #65 from SanctumLabs/dependabot/gradle/io.ktor.plu… #152

Merge pull request #65 from SanctumLabs/dependabot/gradle/io.ktor.plu…

Merge pull request #65 from SanctumLabs/dependabot/gradle/io.ktor.plu… #152

Workflow file for this run

# This workflow will build a Java project with Gradle
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Lint
on: [ push ]
jobs:
dependencies:
name: Dependency Resolution
runs-on: ubuntu-latest
steps:
# Ref: https://github.com/actions/checkout
- name: Checkout
uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'adopt'
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
# Ref: https://github.com/actions/cache
- name: Cache Gradle packages
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Install Dependencies
run: ./gradlew dependencies
lint:
name: Code Linting
runs-on: ubuntu-latest
needs:
- dependencies
steps:
# Ref: https://github.com/actions/checkout
- uses: actions/checkout@v3
- name: Restore Cache
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Lint Application
run: ./gradlew detekt
dockerLint:
name: Dockerfile linting
runs-on: ubuntu-latest
needs:
- dependencies
steps:
- uses: actions/checkout@v3
- uses: hadolint/hadolint-action@v2.1.0
with:
dockerfile: Dockerfile