testOnJenkins

This commit is contained in:
yyeeqii 2025-04-27 11:15:42 +08:00
parent ec50d6a61f
commit 70db606ba6
13 changed files with 789 additions and 361 deletions

View file

@ -0,0 +1 @@
1.5:0a8e3252-0dfa-4c2d-93e4-132058372cdb

View file

@ -0,0 +1 @@
1745717021

View file

@ -0,0 +1 @@
0

View file

@ -0,0 +1 @@
0a8e3252-0dfa-4c2d-93e4-132058372cdb

View file

@ -0,0 +1 @@
43f16e171a7a457e96117ad05e17e9e3

View file

@ -0,0 +1,8 @@
-----BEGIN OPENSSH PRIVATE KEY-----
b3BlbnNzaC1rZXktdjEAAAAABG5vbmUAAAAEbm9uZQAAAAAAAAABAAAAMwAA
AAtzc2gtZWQyNTUxOQAAACCAZpIqWjfT3tGuR4Xz+e6Cw1CXaZT2qvrJhgTJ
nDff7wAAAJAhtFL2IbRS9gAAAAtzc2gtZWQyNTUxOQAAACCAZpIqWjfT3tGu
R4Xz+e6Cw1CXaZT2qvrJhgTJnDff7wAAAEDSvbiNPJz3gaknOq4NpKVeB0ha
EZfwyaBuUPtR/bGLYoBmkipaN9Pe0a5HhfP57oLDUJdplPaq+smGBMmcN9/v
AAAAB3ZhZ3JhbnQBAgMEBQY=
-----END OPENSSH PRIVATE KEY-----

View file

@ -0,0 +1 @@
{"virtualbox":{"/home/vagrant/petclinic":{"guestpath":"/home/vagrant/petclinic","hostpath":"C:/Users/Asus User/Desktop/workspace_SCC/spring-petclinic","disabled":false,"__vagrantfile":true}}}

View file

@ -0,0 +1 @@
C:/Users/Asus User/Desktop/workspace_SCC/spring-petclinic

View file

@ -0,0 +1,12 @@
# Copyright (c) HashiCorp, Inc.
# SPDX-License-Identifier: BUSL-1.1
# This file loads the proper rgloader/loader.rb file that comes packaged
# with Vagrant so that encoded files can properly run with Vagrant.
if ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"]
require File.expand_path(
"rgloader/loader", ENV["VAGRANT_INSTALLER_EMBEDDED_DIR"])
else
raise "Encoded files can't be read outside of the Vagrant installer."
end

47
Vagrantfile vendored Normal file
View file

@ -0,0 +1,47 @@
Vagrant.configure("2") do |config|
# Use the ubuntu/bionic64 box
config.vm.box = "ubuntu/bionic64"
config.vm.boot_timeout = 600000
# Configuring VirtualBox provider settings
config.vm.provider "virtualbox" do |vb|
vb.name = "MyVB"
vb.cpus = 2
vb.memory = "2048"
end
# Configuring VirtualBox network settings
config.vm.network "forwarded_port", guest: 8080, host: 8087
# Configuring VirtualBox folder settings
config.vm.synced_folder ".", "/home/vagrant/petclinic"
# Provisioning with a shell script to run the JAR file
config.vm.provision "shell", inline: <<-SHELL
apt update
apt install -y openjdk-17-jdk git unzip
APP_DIR="/home/vagrant/petclinic"
REPO_URL="https://github.com/yiting68/spring-petclinic.git"
JAR_NAME="spring-petclinic-3.4.0.jar"
SERVICE_NAME="petclinic"
# Clone Spring PetClinic project if does not exist
if [ ! -d "$APP_DIR/.git" ]; then
git clone "$REPO_URL" "$APP_DIR"
# Pull latest changes if project already exists
else
cd "$APP_DIR"
git pull
fi
# Navigate to the project directory
cd "$APP_DIR"
# Build the JAR file
./gradlew build
# Run the JAR file
nohup java -jar build/libs/$JAR_NAME > $APP_DIR/app.log 2>&1 &
SHELL
end

0
app.log Normal file
View file

View file

@ -19,7 +19,7 @@
.navbar a.navbar-brand span {
display: block;
width: 229px;
width: 230px;
height: 44px;
background: url("../images/spring-logo-dataflow.png") -1px -48px no-repeat;
opacity: 0;

File diff suppressed because it is too large Load diff