feat and dev merging (#2)

- Plus and Minus button added for modifier
- better WS:// and WSS:// implementation
- dev: readme adjusted

Reviewed-on: #2
Co-authored-by: riomoo <alister@kamikishi.net>
Co-committed-by: riomoo <alister@kamikishi.net>
This commit is contained in:
riomoo 2026-01-13 09:21:39 -05:00 committed by moobot
parent 82cda6bfe6
commit 62daab494a
Signed by: moobot
GPG key ID: 1F58B1369E1C199C
5 changed files with 112 additions and 41 deletions

41
run.sh
View file

@ -1,41 +0,0 @@
#!/bin/bash
# Define variables for your image and container name.
IMAGE_NAME="localhost/gofudge:latest"
CONTAINER_NAME="gofudge"
# Step 1: Build the new container image.
echo "Building new image: $IMAGE_NAME..."
podman build --force-rm -t "$IMAGE_NAME" .
# Check if the build was successful before proceeding.
if [ $? -ne 0 ]; then
echo "Image build failed. Exiting script."
exit 1
fi
# Step 2: Check if the container is already running.
if podman container exists "$CONTAINER_NAME"; then
echo "Container '$CONTAINER_NAME' already exists. Stopping and removing it..."
# Step 3: Stop the existing container.
podman stop "$CONTAINER_NAME"
# Step 4: Remove the stopped container.
podman rm "$CONTAINER_NAME"
fi
# Step 5: Run a new container from the newly built image.
echo "Starting new container from image: $IMAGE_NAME..."
podman run -d --name "$CONTAINER_NAME" --memory=75m --restart unless-stopped -p 12007:8080 "$IMAGE_NAME"
# Check if the new container started successfully.
if [ $? -ne 0 ]; then
echo "Failed to start new container. Exiting script."
exit 1
fi
# Step 6: Clean up old, unused images.
# This command removes any images that are not being used by a container.
echo "Cleaning up old images..."
podman image prune --force
echo "Update and cleanup complete!"