This commit is contained in:
hm-desk 2025-02-02 00:22:31 +09:00
parent 5ab2680667
commit 7b27feb91e
3 changed files with 233 additions and 0 deletions

85
asign.html Normal file
View File

@ -0,0 +1,85 @@
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>인사말 페이지</title>
<style>
body {
font-family: Arial, sans-serif;
text-align: center;
transition: background-color 0.3s, color 0.3s;
}
.light-mode {
background-color: #ffffff;
color: #000000;
}
.dark-mode {
background-color: #333333;
color: #ffffff;
}
.container {
margin-top: 20vh;
}
button {
padding: 10px 20px;
font-size: 16px;
cursor: pointer;
border: none;
border-radius: 5px;
margin-top: 20px;
}
.light-mode button {
background-color: #000;
color: #fff;
}
.dark-mode button {
background-color: #fff;
color: #000;
}
table {
margin: 20px auto;
border-collapse: collapse;
width: 50%;
}
th, td {
border: 1px solid #000;
padding: 10px;
text-align: center;
}
.dark-mode th, .dark-mode td {
border: 1px solid #fff;
}
</style>
</head>
<body class="light-mode">
<div class="container">
<h1>안녕하세요! 반갑습니다.</h1>
<button onclick="toggleTheme()">다크 모드 전환</button>
<table>
<tr>
<th>name</th>
<th>url</th>
</tr>
<tr>
<td>test page</td>
<td><a href="https://assign.icurfer.com" target="_blank">https://assign.icurfer.com</a></td>
</tr>
</table>
</div>
<script>
function toggleTheme() {
const body = document.body;
body.classList.toggle("dark-mode");
body.classList.toggle("light-mode");
const button = document.querySelector("button");
if (body.classList.contains("dark-mode")) {
button.textContent = "라이트 모드 전환";
} else {
button.textContent = "다크 모드 전환";
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,92 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: greeting-html-config
namespace: toy
data:
index.html: |
<!DOCTYPE html>
<html lang="ko">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>인사말 페이지</title>
<style>
body {
font-family: Arial, sans-serif;
text-align: center;
transition: background-color 0.3s, color 0.3s;
}
.light-mode {
background-color: #ffffff;
color: #000000;
}
.dark-mode {
background-color: #333333;
color: #ffffff;
}
.container {
margin-top: 20vh;
}
button {
padding: 10px 20px;
font-size: 16px;
cursor: pointer;
border: none;
border-radius: 5px;
margin-top: 20px;
}
.light-mode button {
background-color: #000;
color: #fff;
}
.dark-mode button {
background-color: #fff;
color: #000;
}
table {
margin: 20px auto;
border-collapse: collapse;
width: 50%;
}
th, td {
border: 1px solid #000;
padding: 10px;
text-align: center;
}
.dark-mode th, .dark-mode td {
border: 1px solid #fff;
}
</style>
</head>
<body class="light-mode">
<div class="container">
<h1>안녕하세요! 반갑습니다.</h1>
<button onclick="toggleTheme()">다크 모드 전환</button>
<table>
<tr>
<th>name</th>
<th>url</th>
</tr>
<tr>
<td>test page</td>
<td><a href="https://assign.icurfer.com" target="_blank">https://assign.icurfer.com</a></td>
</tr>
</table>
</div>
<script>
function toggleTheme() {
const body = document.body;
body.classList.toggle("dark-mode");
body.classList.toggle("light-mode");
const button = document.querySelector("button");
if (body.classList.contains("dark-mode")) {
button.textContent = "라이트 모드 전환";
} else {
button.textContent = "다크 모드 전환";
}
}
</script>
</body>
</html>

View File

@ -0,0 +1,56 @@
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: assign-ing
namespace: assign
spec:
ingressClassName: nginx
rules:
- host: assign.icurfer.com
http:
paths:
- backend:
service:
name: assign-svc
port:
number: 80
path: /
pathType: Prefix
---
apiVersion: v1
kind: Service
metadata:
name: assign-svc
namespace: assign
spec:
selector:
app: assign
ports:
- protocol: TCP
port: 80
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: assign-dp
namespace: assign
spec:
replicas: 1
selector:
matchLabels:
app: assign
template:
metadata:
labels:
app: assign
spec:
containers:
- name: nginx
image: nginx:latest
volumeMounts:
- name: greeting-html
mountPath: /usr/share/nginx/html
volumes:
- name: greeting-html
configMap:
name: greeting-html-config