improved automated build, removed header, minor adjustments

This commit is contained in:
Jean Jacques Avril 2025-03-02 20:20:58 +00:00
parent 2ab89d122d
commit 198bbd642c
3 changed files with 20 additions and 15 deletions

View File

@ -1,26 +1,32 @@
#!/bin/bash #!/bin/bash
# Set image name and tag # Set variables
IMAGE_NAME="ssvc-rimsting-vote" IMAGE_NAME="ssvc-rimsting-vote"
TAG="latest" TAG="latest"
GITEA_DOMAIN="git.jeanavril.com"
GITEA_USER="jean"
# Build the Docker image # Build the Docker image
echo "Building Docker image: ${IMAGE_NAME}:${TAG}" echo "Building Docker image: ${IMAGE_NAME}:${TAG}"
docker build -t ${IMAGE_NAME}:${TAG} . docker build -t ${IMAGE_NAME}:${TAG} --provenance=false .
# Check if build was successful # Check if build was successful
if [ $? -eq 0 ]; then if [ $? -eq 0 ]; then
echo "Docker image built successfully!" echo "Docker image built successfully!"
echo ""
echo "Image details:" # Tag the image for Gitea
docker images ${IMAGE_NAME}:${TAG} echo "Tagging image for Gitea: ${GITEA_DOMAIN}/${GITEA_USER}/${IMAGE_NAME}:${TAG}"
echo "" docker tag ${IMAGE_NAME}:${TAG} ${GITEA_DOMAIN}/${GITEA_USER}/${IMAGE_NAME}:${TAG}
echo "To run the container:"
echo "docker run -p 3000:3000 ${IMAGE_NAME}:${TAG}" # Push the image to Gitea
echo "" echo "Pushing image to Gitea..."
echo "To run the container with persistent data volume:" docker push ${GITEA_DOMAIN}/${GITEA_USER}/${IMAGE_NAME}:${TAG}
echo "docker run -p 3000:3000 -v $(pwd)/data:/app/data ${IMAGE_NAME}:${TAG}"
echo "Image pushed successfully!"
else else
echo "Error building Docker image" echo "Error building Docker image"
exit 1 exit 1
fi fi
# docker tag ssvc-rimsting-vote:latest git.jeanavril.com/jean/ssvc-rimsting-vote:latest
# docker push git.jeanavril.com/jean/ssvc-rimsting-vote:latest

View File

@ -1,7 +1,6 @@
import type { Metadata } from "next"; import type { Metadata } from "next";
import { Geist, Geist_Mono } from "next/font/google"; import { Geist, Geist_Mono } from "next/font/google";
import Link from "next/link"; import Link from "next/link";
import Image from "next/image";
import "./globals.css"; import "./globals.css";
const geistSans = Geist({ const geistSans = Geist({
@ -29,7 +28,7 @@ export default function RootLayout({
<body <body
className={`${geistSans.variable} ${geistMono.variable} antialiased`} className={`${geistSans.variable} ${geistMono.variable} antialiased`}
> >
<header className="ssvc-header"> {/*<header className="ssvc-header">
<div className="ssvc-logo-container"> <div className="ssvc-logo-container">
<div className="w-24 h-24 relative"> <div className="w-24 h-24 relative">
<div className="absolute inset-0 bg-[#0057a6] flex items-center justify-center text-white font-bold" > <div className="absolute inset-0 bg-[#0057a6] flex items-center justify-center text-white font-bold" >
@ -48,7 +47,7 @@ export default function RootLayout({
<div className="text-sm font-bold">RIMSTING</div> <div className="text-sm font-bold">RIMSTING</div>
</div> </div>
</div> </div>
</header> </header>*/}
<nav className="ssvc-nav"> <nav className="ssvc-nav">
<Link href="/">HOME</Link> <Link href="/">HOME</Link>
<Link href="/admin">ADMIN</Link> <Link href="/admin">ADMIN</Link>

View File

@ -133,7 +133,7 @@ function VotePageContent() {
return ( return (
<div className="container mx-auto px-4 py-8"> <div className="container mx-auto px-4 py-8">
<div className="mb-8"> <div className="mb-8">
<h1 className="text-2xl font-bold text-[#0057a6] mb-4">SATZUNGSÄNDERUNG - ABSTIMMUNG</h1> <h1 className="text-2xl font-bold text-[#0057a6] mb-4">ABSTIMMUNG</h1>
<div className="ssvc-main-content"> <div className="ssvc-main-content">
<form onSubmit={handleSubmit} className="space-y-6"> <form onSubmit={handleSubmit} className="space-y-6">