Skip to content

Instantly share code, notes, and snippets.

......
livenessProbe:
httpGet:
path: /actuator/health/liveness
port: 8080
initialDelaySeconds: 50
periodSeconds: 10
timeoutSeconds: 2
readinessProbe:
httpGet:
management.health.probes.enabled=true
management.endpoint.health.show-details=always
management.endpoint.health.group.readiness.include=*
management.endpoint.health.group.readiness.show-details=always
management.endpoint.health.group.liveness.include=ping
management.endpoint.health.group.liveness.show-details=always
spring.jpa.generate-ddl=true
spring.jpa.hibernate.ddl-auto=none
spring.jpa.hibernate.jdbc.time_zone=UTC
spring.jpa.database-platform=org.hibernate.dialect.MySQL5InnoDBDialect
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/${MYSQL_DB:local_db}?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=UTC
spring.datasource.username=${MYSQL_USER:local_user}
spring.datasource.password=${MYSQL_PASSWORD:P@ssowrd1}
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
spring.jpa.properties.hibernate.show_sql=${SHOW_SQL:false}
spring.jpa.properties.hibernate.jdbc.batch_size=${JDBC_BACTH_SIZE:10}
# Build layer
FROM maven:3.6.3-adoptopenjdk-11 as build
LABEL maintainer="ehabqadah@gmail.com"
ARG GIT_COMMIT
ARG ENVIRONMENT
LABEL service=demo \
stage=build \
@ehabqadah
ehabqadah / Dockerfile
Created January 31, 2022 21:49
PhantomJS with Nodejs on ubuntu (Docker)
FROM ubuntu:latest
WORKDIR /opt/backend
COPY . .
RUN su -
RUN apt-get update
RUN apt-get install sudo -y
RUN sudo apt install curl -y
RUN curl -sL https://deb.nodesource.com/setup_17.x -o nodesource_setup.sh
RUN sudo bash nodesource_setup.sh
@ehabqadah
ehabqadah / App.java
Last active November 30, 2023 13:14
divide_friends
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Queue;
import java.util.Set;
import java.util.stream.Collectors;
public class App {