Skip to content
Merged
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
31 changes: 20 additions & 11 deletions .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
name: Docker Image CI

on:
'on':
push:
branches: [ "main" ]
branches:
- main
pull_request:
branches: [ "main" ]
branches:
- main

jobs:

Expand All @@ -13,11 +15,18 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Build the Docker image
run: docker build . --file ./deployment/Dockerfile --tag arc:$(date +%s)
- shell: bash
env:
SUPER_SECRET: ${{ secrets.SECRET }}
run: |
echo "$SUPER_SECRET"
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'
- name: Build JAR
run: ./gradlew build
- name: Build the Docker image
run: docker build . --file ./deployment/Dockerfile --tag arc:$(date +%s)
- shell: bash
env:
SUPER_SECRET: ${{ secrets.SECRET }}
run: |
echo "$SUPER_SECRET"
2 changes: 1 addition & 1 deletion deployment/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM eclipse-temurin:21-jdk-alpine
VOLUME /tmp
COPY *.jar OpenArc.jar
COPY applications/app-service/build/libs/OpenArc.jar OpenArc.jar
ENV JAVA_OPTS=" -Xshareclasses:name=cacheapp,cacheDir=/cache,nonfatal -XX:+UseContainerSupport -XX:MaxRAMPercentage=70 -Djava.security.egd=file:/dev/./urandom"
# Replace with a non-root user to avoid running the container with excessive privileges
USER appuser
Expand Down