Step 1: Create a file ep.sh
with the following content,
#!/bin/sh
echo "I: Sleeping for 20seconds....."
sleep 20
exec "$@"
#!/bin/bash | |
apt-get update | |
apt-get install -y git wget | |
# Install Docker | |
apt-get install -yq \ | |
apt-transport-https \ | |
ca-certificates \ | |
curl \ |
apiVersion: apps/v1 | |
kind: ReplicaSet | |
metadata: | |
name: vote | |
labels: | |
role: vote | |
spec: | |
replicas: 4 | |
selector: | |
matchLabels: |
Step 1: Create a file ep.sh
with the following content,
#!/bin/sh
echo "I: Sleeping for 20seconds....."
sleep 20
exec "$@"
FROM schoolofdevops/maven:spring AS BUILD | |
WORKDIR /app | |
COPY . . | |
RUN mvn spring-javaformat:apply && \ | |
mvn package -DskipTests | |
FROM openjdk:8u212-jre-alpine3.9 AS PKG | |
WORKDIR /run | |
COPY --from=BUILD /app/target/spring-petclinic-2.3.1.BUILD-SNAPSHOT.jar /run/petclinic.jar | |
EXPOSE 8080 |
version: "3.8" | |
networks: | |
custom: | |
driver: bridge | |
services: | |
app: | |
image: xxxx/petclinic:v5 | |
build: |
FROM schoolofdevops/maven:spring | |
WORKDIR /app | |
COPY . . | |
RUN mvn spring-javaformat:apply && \ | |
mvn package -DskipTests && \ | |
mv target/spring-petclinic-2.3.1.BUILD-SNAPSHOT.jar /run/petclinic.jar |
#!/bin/bash | |
sudo LC_ALL=en_US.UTF-8 add-apt-repository -y ppa:ondrej/php | |
sudo LC_ALL=en_US.UTF-8 add-apt-repository -y ppa:ondrej/apache2 | |
sudo apt update | |
sudo apt install -y software-properties-common language-pack-en-base dialog apt-utils | |
sudo update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 | |
sudo cp /usr/share/zoneinfo/America/New_York /etc/localtime | |
sudo apt install -yq apache2 php5.6 php5.6-mysql mysql-client |
podTemplate( | |
volumes: [ | |
hostPathVolume(hostPath: '/var/run/docker.sock', mountPath: '/var/run/docker.sock') | |
]) | |
) |
version: "3.8" | |
networks: | |
custom: | |
services: | |
app: | |
image: xxxxxx/petclinic:dev | |
build: | |
context: . |
version: "3.8" | |
networks: | |
custom: | |
driver: bridge | |
services: | |
app: | |
image: initcron/petclinic:dev | |
build: |