We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jeremylongshore/waygate-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server
install-systemd-service.shβ’2.88 KiB
#!/bin/bash
# Install Waygate MCP systemd service for auto-start
# Run with: sudo ./scripts/install-systemd-service.sh
set -euo pipefail
# Colors for output
RED='\033[0;31m'
GREEN='\033[0;32m'
YELLOW='\033[1;33m'
BLUE='\033[0;34m'
NC='\033[0m' # No Color
echo -e "${BLUE}π§ Installing Waygate MCP systemd service...${NC}"
# Check if running as root
if [[ $EUID -ne 0 ]]; then
echo -e "${RED}β This script must be run as root (use sudo)${NC}"
exit 1
fi
# Check if docker-compose exists
if ! command -v docker-compose &> /dev/null; then
echo -e "${RED}β docker-compose not found. Please install Docker Compose first.${NC}"
exit 1
fi
# Check if service file exists
SERVICE_FILE="/home/jeremy/waygate-mcp/deployment/waygate-mcp.service"
if [[ ! -f "$SERVICE_FILE" ]]; then
echo -e "${RED}β Service file not found: $SERVICE_FILE${NC}"
exit 1
fi
# Copy service file to systemd directory
echo -e "${YELLOW}π Installing service file...${NC}"
cp "$SERVICE_FILE" /etc/systemd/system/waygate-mcp.service
chown root:root /etc/systemd/system/waygate-mcp.service
chmod 644 /etc/systemd/system/waygate-mcp.service
# Reload systemd daemon
echo -e "${YELLOW}π Reloading systemd daemon...${NC}"
systemctl daemon-reload
# Enable service for auto-start
echo -e "${YELLOW}β‘ Enabling auto-start on boot...${NC}"
systemctl enable waygate-mcp.service
# Ask user if they want to start now
read -p "Start Waygate MCP service now? [y/N]: " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
echo -e "${YELLOW}π Starting Waygate MCP service...${NC}"
systemctl start waygate-mcp.service
# Wait a moment and check status
sleep 5
if systemctl is-active --quiet waygate-mcp.service; then
echo -e "${GREEN}β Waygate MCP service started successfully!${NC}"
# Test health endpoint
echo -e "${YELLOW}π Testing health endpoint...${NC}"
if curl -f http://localhost:8000/health &>/dev/null; then
echo -e "${GREEN}β Health check passed!${NC}"
else
echo -e "${YELLOW}β οΈ Health check failed - service may still be starting${NC}"
fi
else
echo -e "${RED}β Service failed to start. Check logs with: journalctl -u waygate-mcp.service${NC}"
fi
fi
echo -e "\n${BLUE}π Service Management Commands:${NC}"
echo -e " β’ Start: ${YELLOW}sudo systemctl start waygate-mcp.service${NC}"
echo -e " β’ Stop: ${YELLOW}sudo systemctl stop waygate-mcp.service${NC}"
echo -e " β’ Restart: ${YELLOW}sudo systemctl restart waygate-mcp.service${NC}"
echo -e " β’ Status: ${YELLOW}systemctl status waygate-mcp.service${NC}"
echo -e " β’ Logs: ${YELLOW}journalctl -f -u waygate-mcp.service${NC}"
echo -e " β’ Disable: ${YELLOW}sudo systemctl disable waygate-mcp.service${NC}"
echo -e "\n${GREEN}β Waygate MCP systemd service installation complete!${NC}"
echo -e "${BLUE}π Service will now auto-start on system boot${NC}"