From 9b7a5a4b51eea82a29e6fb8abe57935108d181aa Mon Sep 17 00:00:00 2001 From: Jon Staab Date: Thu, 16 Oct 2025 10:34:18 -0700 Subject: [PATCH] Remove vanilla deployment instructions --- Dockerfile | 6 +++--- README.md | 51 ++++----------------------------------------------- nginx.conf | 25 ------------------------- zooid.service | 18 ------------------ 4 files changed, 7 insertions(+), 93 deletions(-) delete mode 100644 nginx.conf delete mode 100644 zooid.service diff --git a/Dockerfile b/Dockerfile index 58600ea..7d439d1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -21,8 +21,8 @@ USER nonroot:nonroot EXPOSE 3334 -ENV CONFIG=/tmp/config -ENV MEDIA=/tmp/media -ENV DATA=/tmp/data +ENV CONFIG=/app/config +ENV MEDIA=/app/media +ENV DATA=/app/data ENTRYPOINT ["/bin/zooid"] diff --git a/README.md b/README.md index f9785ec..58118a0 100644 --- a/README.md +++ b/README.md @@ -111,59 +111,16 @@ can_manage = true See `justfile` for defined commands. -## Deploying on ubuntu - -```sh -# Add a user -adduser zooid - -# Install system dependencies -sudo apt update -apt install nginx git certbot python3-certbot-nginx sqlite3 gcc - -# Install go and add it to path -wget -qO- https://go.dev/dl/go1.25.1.linux-amd64.tar.gz | sudo tar -C /usr/local -xzf - -echo 'export PATH=$PATH:/usr/local/go/bin' >> /etc/profile - -# Log in as your user -su --login zooid - -# Clone the repository and build -git clone https://github.com/coracle-social/zooid.git ~/zooid && cd ~/zooid -CGO_ENABLED=1 go build -o bin/zooid cmd/relay/main.go - -# Back to root -exit - -# Add a service file - edit if needed -cp /home/zooid/zooid/zooid.service /etc/systemd/system/zooid.service - -# Start the service -systemctl enable zooid -service zooid start - -# Set up a SSL certificate -# Use another method or --manual-auth-hook and --manual-cleanup-hook to automate renewal -certbot certonly --manual -d '*.yourdomain.com' --preferred-challenges=dns - -# Set up nginx - be sure to edit the server_name to your domain -cp /home/zooid/zooid/nginx.conf /etc/nginx/sites-available/zooid.conf -ln -s /etc/nginx/sites-{available,enabled}/zooid.conf - -# Enable the site and restart nginx -service nginx restart -``` - -## Deploying via container +## Deploying Zooid can be run using an OCI container: ```sh podman run -it \ -p 3334:3334 \ - -v ./config:/tmp/config \ - -v ./media:/tmp/media \ - -v ./data:/tmp/data \ + -v ./config:/app/config \ + -v ./media:/app/media \ + -v ./data:/app/data \ ghcr.io/coracle-social/zooid ``` diff --git a/nginx.conf b/nginx.conf deleted file mode 100644 index 88df073..0000000 --- a/nginx.conf +++ /dev/null @@ -1,25 +0,0 @@ -server { - listen 443 ssl; - server_name *.yourdomain.com; - - ssl_certificate /etc/letsencrypt/live/yourdomain.com/fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live/yourdomain.com/privkey.pem; - - ssl_protocols TLSv1.2 TLSv1.3; - ssl_prefer_server_ciphers on; - - location / { - proxy_pass http://127.0.0.1:3334; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "Upgrade"; - proxy_set_header Host $host; - } -} - -server { - listen 80; - server_name *.yourdomain.com; - - return 301 https://$host$request_uri; -} diff --git a/zooid.service b/zooid.service deleted file mode 100644 index c40a91a..0000000 --- a/zooid.service +++ /dev/null @@ -1,18 +0,0 @@ -[Unit] -Description=zooid -After=network.target - -[Service] -Type=simple -User=zooid -Group=zooid -WorkingDirectory=/home/zooid/zooid -ExecStart=/home/zooid/zooid/bin/zooid -Restart=always -RuntimeMaxSec=3600 -StandardOutput=syslog -StandardError=syslog -SyslogIdentifier=zooid - -[Install] -WantedBy=multi-user.target