Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: FudanSELab/train-ticket
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: docc-lab/train-ticket
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Able to merge. These branches can be automatically merged.
  • 5 commits
  • 4 files changed
  • 1 contributor

Commits on Aug 2, 2024

  1. Copy the full SHA
    461fa84 View commit details

Commits on Sep 23, 2024

  1. Copy the full SHA
    29293c8 View commit details
  2. Copy the full SHA
    d87e5e5 View commit details

Commits on Oct 16, 2024

  1. Copy the full SHA
    1f8633f View commit details
  2. Copy the full SHA
    363078d View commit details
Original file line number Diff line number Diff line change
@@ -52,13 +52,6 @@ spec:
name: nacos
ports:
- containerPort: 18767
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18767
@@ -120,13 +113,6 @@ spec:
name: nacos
ports:
- containerPort: 16112
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16112
@@ -188,13 +174,6 @@ spec:
name: nacos
ports:
- containerPort: 16113
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16113
@@ -256,13 +235,6 @@ spec:
name: nacos
ports:
- containerPort: 16114
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16114
@@ -324,13 +296,6 @@ spec:
name: nacos
ports:
- containerPort: 16115
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16115
@@ -394,13 +359,6 @@ spec:
name: nacos
ports:
- containerPort: 18888
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18888
@@ -464,13 +422,6 @@ spec:
name: nacos
ports:
- containerPort: 12340
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12340
@@ -532,13 +483,6 @@ spec:
name: nacos
ports:
- containerPort: 17001
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 17001
@@ -600,13 +544,6 @@ spec:
name: nacos
ports:
- containerPort: 15680
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 15680
@@ -668,13 +605,6 @@ spec:
name: nacos
ports:
- containerPort: 18885
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18885
@@ -738,13 +668,6 @@ spec:
name: nacos
ports:
- containerPort: 15679
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 15679
@@ -808,13 +731,6 @@ spec:
name: nacos
ports:
- containerPort: 16110
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16110
@@ -878,13 +794,6 @@ spec:
name: nacos
ports:
- containerPort: 16111
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16111
@@ -948,13 +857,6 @@ spec:
name: nacos
ports:
- containerPort: 12347
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12347
@@ -1020,13 +922,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 18808
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18808
@@ -1088,13 +983,6 @@ spec:
name: nacos
ports:
- containerPort: 12386
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12386
@@ -1158,13 +1046,6 @@ spec:
name: nacos
ports:
- containerPort: 18957
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18957
@@ -1230,13 +1111,6 @@ spec:
name: ts-food-mysql
ports:
- containerPort: 18856
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18856
@@ -1298,13 +1172,6 @@ spec:
name: nacos
ports:
- containerPort: 18888
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 4000m
memory: 4000Mi
readinessProbe:
tcpSocket:
port: 18888
@@ -1368,13 +1235,6 @@ spec:
name: nacos
ports:
- containerPort: 18673
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18673
@@ -1436,13 +1296,6 @@ spec:
name: nacos
ports:
- containerPort: 12862
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12862
@@ -1508,13 +1361,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 17853
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 17853
@@ -1580,13 +1426,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 12032
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12032
@@ -1652,13 +1491,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 12031
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12031
@@ -1722,13 +1554,6 @@ spec:
name: nacos
ports:
- containerPort: 19001
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 19001
@@ -1792,13 +1617,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 14569
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 14569
@@ -1862,13 +1680,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 14568
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 14568
@@ -1932,13 +1743,6 @@ spec:
name: nacos
ports:
- containerPort: 16579
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16579
@@ -2002,13 +1806,6 @@ spec:
name: rabbitmq
ports:
- containerPort: 18886
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18886
@@ -2070,13 +1867,6 @@ spec:
name: nacos
ports:
- containerPort: 14578
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 14578
@@ -2140,13 +1930,6 @@ spec:
name: nacos
ports:
- containerPort: 11178
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 11178
@@ -2208,13 +1991,6 @@ spec:
name: nacos
ports:
- containerPort: 18898
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18898
@@ -2278,13 +2054,6 @@ spec:
name: nacos
ports:
- containerPort: 11188
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 11188
@@ -2348,13 +2117,6 @@ spec:
name: nacos
ports:
- containerPort: 18855
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 18855
@@ -2418,13 +2180,6 @@ spec:
name: nacos
ports:
- containerPort: 12345
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12345
@@ -2488,13 +2243,6 @@ spec:
name: nacos
ports:
- containerPort: 16108
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16108
@@ -2558,13 +2306,6 @@ spec:
name: nacos
ports:
- containerPort: 19999
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 19999
@@ -2628,13 +2369,6 @@ spec:
name: nacos
ports:
- containerPort: 14567
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 14567
@@ -2696,13 +2430,6 @@ spec:
name: nacos
ports:
- containerPort: 14322
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 14322
@@ -2766,13 +2493,6 @@ spec:
name: nacos
ports:
- containerPort: 12346
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12346
@@ -2836,13 +2556,6 @@ spec:
name: nacos
ports:
- containerPort: 16346
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16346
@@ -2906,13 +2619,6 @@ spec:
name: nacos
ports:
- containerPort: 12342
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 12342
@@ -2974,13 +2680,6 @@ spec:
name: nacos
ports:
- containerPort: 15678
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 15678
@@ -3018,13 +2717,6 @@ spec:
name: nacos
ports:
- containerPort: 16101
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 16101
@@ -3088,13 +2780,6 @@ spec:
name: nacos
ports:
- containerPort: 17525
resources:
requests:
cpu: 100m
memory: 300Mi
limits:
cpu: 500m
memory: 2000Mi
readinessProbe:
tcpSocket:
port: 17525
@@ -3122,10 +2807,3 @@ spec:
imagePullPolicy: IfNotPresent
ports:
- containerPort: 8080
resources:
requests:
cpu: 50m
memory: 100Mi
limits:
cpu: 500m
memory: 500Mi
23 changes: 16 additions & 7 deletions deployment/kubernetes-manifests/skywalking/es.yml
Original file line number Diff line number Diff line change
@@ -37,6 +37,22 @@ spec:
labels:
run: elasticsearch
spec:
nodeSelector:
skywalking: "true"
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: skywalking
operator: In
values:
- "true"
tolerations:
- key: "dedicated"
operator: "Equal"
value: "skywalking"
effect: "NoSchedule"
containers:
- env:
- name: discovery.type
@@ -50,11 +66,4 @@ spec:
- containerPort: 9300
name: tramsport
protocol: TCP
resources:
limits:
cpu: 500m
memory: 2Gi
requests:
cpu: 500m
memory: 2Gi
status: {}
54 changes: 32 additions & 22 deletions deployment/kubernetes-manifests/skywalking/skywalking.yml
Original file line number Diff line number Diff line change
@@ -7,9 +7,7 @@ data:
STORAGE_ES_CLUSTER_NODES: 'elasticsearch:9200'
CORE_GRPC_PORT: '11800'
CORE_REST_PORT: '12800'

---

apiVersion: apps/v1
kind: Deployment
metadata:
@@ -26,6 +24,22 @@ spec:
labels:
app: skywalking
spec:
nodeSelector:
skywalking: "true"
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: skywalking
operator: In
values:
- "true"
tolerations:
- key: "dedicated"
operator: "Equal"
value: "skywalking"
effect: "NoSchedule"
containers:
- envFrom:
- prefix: SW_
@@ -41,13 +55,6 @@ spec:
- containerPort: 11800
name: grpc
protocol: TCP
resources:
limits:
cpu: '2'
memory: 2Gi
requests:
cpu: '1'
memory: 2Gi
volumeMounts:
- mountPath: /etc/localtime
name: volume-localtime
@@ -56,9 +63,7 @@ spec:
path: /etc/localtime
type: ''
name: volume-localtime

---

apiVersion: v1
kind: Service
metadata:
@@ -78,9 +83,7 @@ spec:
targetPort: 11800
selector:
app: skywalking

---

apiVersion: apps/v1
kind: Deployment
metadata:
@@ -97,6 +100,22 @@ spec:
labels:
app: skywalking-ui
spec:
nodeSelector:
skywalking: "true"
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: skywalking
operator: In
values:
- "true"
tolerations:
- key: "dedicated"
operator: "Equal"
value: "skywalking"
effect: "NoSchedule"
containers:
- env:
- name: SW_OAP_ADDRESS
@@ -108,13 +127,6 @@ spec:
- containerPort: 8080
name: http
protocol: TCP
resources:
limits:
cpu: '2'
memory: 1Gi
requests:
cpu: '1'
memory: 1Gi
volumeMounts:
- mountPath: /etc/localtime
name: volume-localtime
@@ -123,9 +135,7 @@ spec:
path: /etc/localtime
type: ''
name: volume-localtime

---

apiVersion: v1
kind: Service
metadata:
61 changes: 50 additions & 11 deletions hack/deploy/gen-mysql-secret.sh
Original file line number Diff line number Diff line change
@@ -66,28 +66,67 @@ function update_tt_dp_cm {
nacosCM="$1"
rabbitmqCM="$2"

echo "Updating deploy.yaml with nacos=${nacosCM} and rabbitmq=${rabbitmqCM}"
echo "Sample file: $dp_sample_yaml"
echo "Target file: $dp_yaml"
if [ ! -f "$dp_sample_yaml" ]; then
echo "Error: $dp_sample_yaml does not exist"
return 1
fi

cp $dp_sample_yaml $dp_yaml

if [ "$(uname)"="Darwin" ]; then
sed -i "" "s/nacos/${nacosCM}/g" $dp_yaml
sed -i "" "s/rabbitmq/${rabbitmqCM}/g" $dp_yaml
else
sed -i "s/nacos/${nacosCM}/g" $dp_yaml
sed -i "s/rabbitmq/${rabbitmqCM}/g" $dp_yaml
if [ ! -f "$dp_yaml" ]; then
echo "Error: Failed to create $dp_yaml"
return 1
fi

sed -i.bak "s/nacos/${nacosCM}/g" $dp_yaml && rm ${dp_yaml}.bak
sed -i.bak "s/rabbitmq/${rabbitmqCM}/g" $dp_yaml && rm ${dp_yaml}.bak


}

function update_tt_sw_dp_cm {
nacosCM="$1"
rabbitmqCM="$2"
echo "Current directory: $(pwd)"
echo "Sample file path: $sw_dp_sample_yaml"
echo "Target file path: $sw_dp_yaml"

echo "Copying sample file..."
cp $sw_dp_sample_yaml $sw_dp_yaml
if [ "$(uname)"="Darwin" ]; then
sed -i "" "s/nacos/${nacosCM}/g" $sw_dp_yaml
sed -i "" "s/rabbitmq/${rabbitmqCM}/g" $sw_dp_yaml
if [ -f "$sw_dp_yaml" ]; then
echo "File copied successfully"
else
echo "Failed to copy file"
return 1
fi

echo "Updating file with nacos=${nacosCM} and rabbitmq=${rabbitmqCM}"

# Add error checking for sed commands
if sed -i "s/nacos/${nacosCM}/g" $sw_dp_yaml; then
echo "Nacos replacement successful"
else
echo "Nacos replacement failed"
return 1
fi

if sed -i "s/rabbitmq/${rabbitmqCM}/g" $sw_dp_yaml; then
echo "RabbitMQ replacement successful"
else
echo "RabbitMQ replacement failed"
return 1
fi

echo "File update complete"

# Check if any changes were made
if diff $sw_dp_sample_yaml $sw_dp_yaml > /dev/null; then
echo "Warning: No changes were made to the file"
else
sed -i "s/nacos/${nacosCM}/g" $sw_dp_yaml
sed -i "s/rabbitmq/${rabbitmqCM}/g" $sw_dp_yaml
echo "Changes were successfully made to the file"
fi
}