Firefishæ¯Misskeyçäžäžªåæ¯ïŒå ·æå€é¡¹æ¹è¿åé误修å€ãFirefishäžMisskeyçæŸèå·®åŒïŒäž»èŠåšä»¥äžå 䞪æ¹é¢ïŒæèªFirefish项ç®é¡µé¢çä»ç»ïŒïŒ
Improved UI/UX (especially on mobile)
Post editing
Content importing
Improved notifications
Improved server security
Improved accessibility
Improved threads
Recommended Servers timeline
OCR image captioning
New and improved Groups
Better intro tutorial
Compatibility with Mastodon clients/apps
Backfill user information
Advanced search
Many more user and admin settings
Many bug fixes and performance improvements
Link verification
So much more!
äžé¢çå®è£ æ¥éª€åºäºdebian12 ARM64ãå®è£ éèŠçšå°ç蜯件å ïŒ
apt -y update apt -y install curl nginx python3-certbot-nginx
å®è£ dockerïŒ
curl -fsSL https://get.docker.com -o get-docker.sh sh get-docker.sh
æ°å»ºç®åœä»¥ådocker-composeæ件ïŒ
mkdir -p /opt/firefish/config && cd /opt/firefish && nano docker-compose.yml
åå ¥åŠäžé 眮ïŒ
version: '3.8' services: web: image: registry.joinfirefish.org/firefish/firefish:arm64 container_name: firefish_web restart: unless-stopped depends_on: - db - redis - meilisearch ports: - "127.0.0.1:3000:3000" networks: - calcnet environment: - NODE_ENV=production volumes: - ./files:/firefish/files - ./config:/firefish/.config:ro db: image: docker.io/postgres:14-alpine container_name: firefish_db restart: unless-stopped networks: - calcnet environment: - POSTGRES_DB=firefish - POSTGRES_USER=imlala - POSTGRES_PASSWORD=setyourdbpasswd volumes: - ./db:/var/lib/postgresql/data redis: image: docker.io/redis:7.0-alpine container_name: firefish_redis restart: unless-stopped networks: - calcnet volumes: - ./redis:/data meilisearch: container_name: firefish_meilisearch image: getmeili/meilisearch:v1.4 restart: unless-stopped networks: - calcnet environment: - MEILI_ENV=production - MEILI_MASTER_KEY=setyourapikey - MEILI_NO_ANALYTICS=true volumes: - ./meili_data:/meili_data networks: calcnet:
åšconfigç®åœäžæ°å»ºäžäžªfirefishéèŠçšå°çé 眮æ件ïŒ
nano config/default.yml
åå ¥åŠäžé 眮ïŒéèŠæ¹åšçå°æ¹åé¢æäŒè¯Šç»ä»ç»ïŒ
#âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ # Firefish configuration #âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ # After starting your server, please don't change the URL! Doing so will break federation. # âââââââ #ââââ URL ââââââââââââââââââââââââââââââââââââââââââââââââââââââ # Final accessible URL seen by a user. url: https://example.com/ # âââââââââââââââââââââââââ #ââââ Port and TLS settings ââââââââââââââââââââââââââââââââââââ # # Firefish requires a reverse proxy to support HTTPS connections. # # +----- https://example.com/ ------------+ # +------+ |+-------------+ +----------------+| # | User | ---> || Proxy (443) | ---> | Firefish (3000) || # +------+ |+-------------+ +----------------+| # +---------------------------------------+ # # You need to set up a reverse proxy. (e.g. nginx, caddy) # An encrypted connection with HTTPS is highly recommended # because tokens may be transferred in GET requests. # The port that your Firefish server should listen on. port: 3000 # The bind host your Firefish server should listen on. # If unspecified, the wildcard address will be used. #bind: 127.0.0.1 # ââââââââââââââââââââââââââââ #ââââ PostgreSQL configuration âââââââââââââââââââââââââââââââââ db: host: localhost port: 5432 #ssl: false # Database name db: firefish # Auth user: example-firefish-user pass: example-firefish-pass # Whether disable Caching queries #disableCache: true # Extra Connection options #extra: # ssl: # host: localhost # rejectUnauthorized: false # âââââââââââââââââââââââ #ââââ Redis configuration ââââââââââââââââââââââââââââââââââââââ redis: host: localhost port: 6379 #tls: # host: localhost # rejectUnauthorized: false #family: 0 # 0=Both, 4=IPv4, 6=IPv6 #pass: example-pass #prefix: example-prefix #db: 1 #user: default # âââââââââââââââââââââââââââââââ #ââââ Cache server configuration ââââââââââââââââââââââââââââââââââââââ # A Redis-compatible server (DragonflyDB, Keydb, Redis) for caching # If left blank, it will use the Redis server from above #cacheServer: #host: localhost #port: 6379 #family: 0 # 0=Both, 4=IPv4, 6=IPv6 #pass: example-pass #prefix: example-prefix #db: 1 # Please configure either MeiliSearch *or* Sonic. # If both MeiliSearch and Sonic configurations are present, MeiliSearch will take precedence. # âââââââââââââââââââââââââââââ #ââââ MeiliSearch configuration ââââââââââââââââââââââââââââââââââââââ #meilisearch: # host: meilisearch # port: 7700 # ssl: false # apiKey: # âââââââââââââââââââââââ #ââââ Sonic configuration ââââââââââââââââââââââââââââââââââââââ #sonic: # host: localhost # port: 1491 # auth: SecretPassword # collection: notes # bucket: default # âââââââââââââââââ #ââââ ID generation ââââââââââââââââââââââââââââââââââââââââââââ # No need to uncomment in most cases, but you may want to change # these settings if you plan to run a large and/or distributed server. # cuid: # # Min 16, Max 24 # length: 16 # # # Set this to a unique string across workers (e.g., machine's hostname) # # if your workers are running in multiple hosts. # fingerprint: my-fingerprint # âââââââââââââââââââââââ #ââââ Other configuration ââââââââââââââââââââââââââââââââââââââ # Maximum length of a post (default 3000, max 100000) #maxNoteLength: 3000 # Maximum length of an image caption (default 1500, max 8192) #maxCaptionLength: 1500 # Reserved usernames that only the administrator can register with reservedUsernames: [ 'root', 'admin', 'administrator', 'me', 'system' ] # Whether disable HSTS #disableHsts: true # Number of worker processes by type. # The sum must not exceed the number of available cores. #clusterLimits: # web: 1 # queue: 1 # Job concurrency per worker # deliverJobConcurrency: 128 # inboxJobConcurrency: 16 # Job rate limiter # deliverJobPerSec: 128 # inboxJobPerSec: 16 # Job attempts # deliverJobMaxAttempts: 12 # inboxJobMaxAttempts: 8 # Local address used for outgoing requests #outgoingAddress: 127.0.0.1 # IP address family used for outgoing request (ipv4, ipv6 or dual) #outgoingAddressFamily: ipv4 # Syslog option #syslog: # host: localhost # port: 514 # Proxy for HTTP/HTTPS #proxy: http://127.0.0.1:3128 #proxyBypassHosts: [ # 'web.kaiteki.app', # 'example.com', # '192.0.2.8' #] # Proxy for SMTP/SMTPS #proxySmtp: http://127.0.0.1:3128 # use HTTP/1.1 CONNECT #proxySmtp: socks4://127.0.0.1:1080 # use SOCKS4 #proxySmtp: socks5://127.0.0.1:1080 # use SOCKS5 # Media Proxy #mediaProxy: https://example.com/proxy # Proxy remote files (default: false) #proxyRemoteFiles: true #allowedPrivateNetworks: [ # '127.0.0.1/32' #] # TWA #twa: # nameSpace: android_app # packageName: tld.domain.twa # sha256CertFingerprints: ['AB:CD:EF'] # Upload or download file size limits (bytes) #maxFileSize: 262144000 #âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ # Congrats, you've reached the end of the config file needed for most deployments! # Enjoy your Firefish server! #âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ #âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ # Managed hosting settings # >>> NORMAL SELF-HOSTERS, STAY AWAY! <<< # >>> YOU DON'T NEED THIS! <<< # Each category is optional, but if each item in each category is mandatory! # If you mess this up, that's on you, you've been warned... #âââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââââ #maxUserSignups: 100 #isManagedHosting: true #deepl: # managed: true # authKey: '' # isPro: false # #email: # managed: true # address: '[email protected]' # host: 'email.com' # port: 587 # user: '[email protected]' # pass: '' # useImplicitSslTls: false # #objectStorage: # managed: true # baseUrl: '' # bucket: '' # prefix: '' # endpoint: '' # region: '' # accessKey: '' # secretKey: '' # useSsl: true # connnectOverProxy: false # setPublicReadOnUpload: true # s3ForcePathStyle: true # !!!!!!!!!! # >>>>>> AGAIN, NORMAL SELF-HOSTERS, STAY AWAY! <<<<<< # >>>>>> YOU DON'T NEED THIS, ABOVE SETTINGS ARE FOR MANAGED HOSTING ONLY! <<<<<< # !!!!!!!!!! # Seriously. Do NOT fill out the above settings if you're self-hosting. # They're much better off being set from the control panel.
äžé¢è¿äžªé 眮æ件æ¯å®æ¹çé»è®€é 眮ïŒçäžå»æåŸå€å 容ïŒäœå®é äžéèŠæ¹åšçå°æ¹äžå€ïŒäœ åªéèŠæ¹åšäžé¢æååºçè¿äºé 眮项å³å¯ïŒ
1ãé 眮ç«ç¹ååïŒ
âââââââ ââââ URL ââââââââââââââââââââââââââââââââââââââââââââââââââââââ url: https://firefish.example.com/
2ãé 眮æ°æ®åºè¿æ¥ïŒ
ââââââââââââââââââââââââââââ ââââ PostgreSQL configuration âââââââââââââââââââââââââââââââââ db: host: db // host对åºdocker-composeå çserviceså port: 5432 ... db: firefish // åºè®Ÿçœ®äžºPOSTGRES_DBåéçåŒ user: imlala // åºè®Ÿçœ®äžºPOSTGRES_USERåéçåŒ pass: setyourdbpasswd // åºè®Ÿçœ®äžºPOSTGRES_PASSWORDåéçåŒ ...
3ãé 眮RedisïŒ
âââââââââââââââââââââââ ââââ Redis configuration ââââââââââââââââââââââââââââââââââââââ redis: host: redis // host对åºdocker-composeå çserviceså port: 6379 ...
4ãé 眮MeilisearchïŒ
âââââââââââââââââââââââââââââ ââââ MeiliSearch configuration ââââââââââââââââââââââââââââââââââââââ meilisearch: host: meilisearch port: 7700 ssl: false apiKey: setyourapikey // åºè®Ÿçœ®äžºMEILI_MASTER_KEYåéçåŒ ...
å ¶ä»ç倧å€æ°é 眮å 容éœå¯ä»¥çšååšåå°ç®¡çé¢æ¿è¿è¡ä¿®æ¹ãç°åšäœ åªéæåéå并å¯åšå®¹åšïŒ
docker compose up -d
æ¥ç容åšè¿è¡ç¶æïŒç¡®ä¿STATUSéœæ¯UPïŒ
æ¥äžæ¥é 眮NGINXåå代çïŒæ°å»ºNGINXç«ç¹é 眮æ件ïŒ
nano /etc/nginx/sites-available/firefish
åå ¥åŠäžé 眮ïŒ
map $http_upgrade $connection_upgrade { default upgrade; '' close; } proxy_cache_path /tmp/nginx_cache levels=1:2 keys_zone=cache1:16m max_size=1g inactive=720m use_temp_path=off; server { listen 80; server_name firefish.example.com; client_max_body_size 0; location / { proxy_pass http://127.0.0.1:3000; proxy_set_header Host $host; proxy_http_version 1.1; proxy_redirect off; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto https; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; proxy_cache cache1; proxy_cache_lock on; proxy_cache_use_stale updating; add_header X-Cache $upstream_cache_status; } }
å¯çšç«ç¹ïŒ
ln -s /etc/nginx/sites-available/firefish /etc/nginx/sites-enabled/firefish
çŸåSSLè¯ä¹ŠïŒ
certbot --nginx
ç°åšè®¿é®äœ çç«ç¹ïŒå建管çå莊å·å³å®æå šéšå®è£ è¿çšäºã
äžç¹æ³šæäºé¡¹ïŒåŠæäœ çmeilisearchæ¯åç»å®è£ çïŒå³å®è£ meilisearchçæ¶åå®äŸå å·²ç»æåžåäºïŒäžºäºèœå€æ玢å°ææå 容ïŒäœ è¿éèŠåšåå°ç¹äžäžè¿äžªçŽ¢åŒåžåïŒ
è¿éç空ïŒçŽ¢åŒå šéšå 容ïŒ
åèïŒ
https://www.meilisearch.com/docs/learn/configuration/instance_options
https://raw.Githubusercontent.com/meilisearch/meilisearch/latest/config.toml
https://git.joinfirefish.org/firefish/firefish/-/blob/develop/docs/docker.md