Skip to content

Commit

Permalink
[modules]: refactored
Browse files Browse the repository at this point in the history
  • Loading branch information
vlaship committed Jan 22, 2024
1 parent 8fb045d commit 9700bf5
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 41 deletions.
78 changes: 39 additions & 39 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,53 +10,53 @@ permissions:
contents: read

jobs:
# gradle-docker-build:
#
# runs-on: ubuntu-latest
# if: github.event_name == 'push' && github.ref != 'refs/heads/master'
#
# steps:
# - name: Checkout
# uses: actions/checkout@v4
#
# - name: Set up JDK
# uses: actions/setup-java@v4
# with:
# java-version: '21'
# distribution: 'zulu'
#
# - name: Cache Gradle dependencies
# 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: Change wrapper permissions
# run: chmod +x ./gradlew
#
# - name: Build with Gradle
# run: ./gradlew clean backoffice-app:unpack -x test --no-daemon
#
# - name: Build Docker image
# uses: docker/build-push-action@v3
# with:
# context: .
# file: ./unpacked.Dockerfile

docker-build:
gradle-docker-build:

runs-on: ubuntu-latest
if: github.event_name == 'push' && github.ref != 'refs/heads/master'

steps:
- name: Checkout
uses: actions/checkout@v4

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

- name: Cache Gradle dependencies
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: Change wrapper permissions
run: chmod +x ./gradlew

- name: Build with Gradle
run: ./gradlew clean backoffice-app:unpack -x test --no-daemon

- name: Build Docker image
uses: docker/build-push-action@v3
with:
context: .
file: ./gradle.Dockerfile
file: ./unpacked.Dockerfile

# docker-build:
#
# runs-on: ubuntu-latest
#
# steps:
# - name: Checkout
# uses: actions/checkout@v4
#
# - name: Build Docker image
# uses: docker/build-push-action@v3
# with:
# context: .
# file: ./gradle.Dockerfile
2 changes: 0 additions & 2 deletions gradle.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ WORKDIR /
# Copy the source code into the container
COPY . .

RUN ls -la

# Build
RUN ./gradlew clean backoffice-app:unpack -x test --no-daemon

Expand Down

0 comments on commit 9700bf5

Please sign in to comment.