diff --git a/.config/LICENSE b/.config/LICENSE index cb57aef95..2e3e984ec 100644 --- a/.config/LICENSE +++ b/.config/LICENSE @@ -1,4 +1,5 @@ -Copyright 2023 Firefish +Copyright 2023 The Iceshrimp contributors +Copyright 2023 The Firefish contributors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/.config/helm_values_example.yml b/.config/helm_values_example.yml index 5c86acca3..ee473993d 100644 --- a/.config/helm_values_example.yml +++ b/.config/helm_values_example.yml @@ -8,7 +8,7 @@ resources: cpu: 1 memory: 1Gi -firefish: +iceshrimp: domain: example.tld smtp: from_address: noreply@example.tld diff --git a/.weblate b/.weblate index 56430a1bb..3ecf97a5a 100644 --- a/.weblate +++ b/.weblate @@ -1,3 +1,3 @@ [weblate] url = https://hosted.weblate.org/api/ -translation = firefish/locales +translation = iceshrimp/locales diff --git a/.woodpecker/dockerHubRelease.yml b/.woodpecker/dockerHubRelease.yml index 77b1197dc..83d531e15 100644 --- a/.woodpecker/dockerHubRelease.yml +++ b/.woodpecker/dockerHubRelease.yml @@ -2,7 +2,7 @@ pipeline: publish-docker-latest: image: plugins/kaniko settings: - repo: thatonecalculator/firefish + repo: iceshrimp/iceshrimp tags: latest dockerfile: Dockerfile username: diff --git a/.woodpecker/dockerHubReleaseCandidate.yml b/.woodpecker/dockerHubReleaseCandidate.yml index dd0d9354d..aed4a2013 100644 --- a/.woodpecker/dockerHubReleaseCandidate.yml +++ b/.woodpecker/dockerHubReleaseCandidate.yml @@ -2,7 +2,7 @@ pipeline: publish-docker-latest: image: plugins/kaniko settings: - repo: thatonecalculator/firefish + repo: iceshrimp/iceshrimp tags: rc dockerfile: Dockerfile username: diff --git a/.woodpecker/dockerHubTag.yml b/.woodpecker/dockerHubTag.yml index 4ff3f0502..6be5f1d97 100644 --- a/.woodpecker/dockerHubTag.yml +++ b/.woodpecker/dockerHubTag.yml @@ -2,7 +2,7 @@ pipeline: publish-docker-tag: image: plugins/kaniko settings: - repo: thatonecalculator/firefish + repo: iceshrimp/iceshrimp # Uses the tag from git for the container tag tags: ${CI_COMMIT_TAG} dockerfile: Dockerfile diff --git a/.woodpecker/testDocker.yml b/.woodpecker/testDocker.yml index 8c5e2cf9d..3b14b2830 100644 --- a/.woodpecker/testDocker.yml +++ b/.woodpecker/testDocker.yml @@ -2,7 +2,7 @@ pipeline: docker-build: image: plugins/kaniko settings: - repo: thatonecalculator/firefish + repo: iceshrimp/iceshrimp tags: test dockerfile: Dockerfile no_push: true diff --git a/CHANGELOG.md b/CHANGELOG.md index c2a379d42..48107a760 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -All changes from v13.0.0 onwards, for a list of differences read FIREFISH.md +All changes from v13.0.0 onwards, for a list of differences read CHANGES_FROM_UPSTREAM.md ## [1.0.0] - 2023-07-19 diff --git a/CHANGES_FROM_UPSTREAM.md b/CHANGES_FROM_UPSTREAM.md index 26bdcf760..9fee800ab 100644 --- a/CHANGES_FROM_UPSTREAM.md +++ b/CHANGES_FROM_UPSTREAM.md @@ -85,7 +85,7 @@ - Undo renote button inside original note - Custom locales - Obliteration of Ai-chan -- Switch to [Firefish.js](https://codeberg.org/firefish/firefish.js) +- Switch to [Iceshrimp.js](https://iceshrimp.dev/iceshrimp/iceshrimp/) - Woozy mode ๐Ÿฅด - Improve blocking servers - Release notes diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index 4f215e829..7a8574250 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -60,10 +60,7 @@ representative at an online or offline event. ## Enforcement Instances of abusive, harassing, or otherwise unacceptable behavior may be -reported to the community leaders responsible for enforcement at -@thatonecalculator on Codeberg, -`@kainoa@firefish.social` on the Fediverse, -or kainoa@t1c.dev via email. +reported to the community leaders responsible for enforcement at `conduct@iceshrimp.dev`. All complaints will be reviewed and investigated promptly and fairly. All community leaders are obligated to respect the privacy and security of the diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b85a9360d..09a6962f5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,26 +1,24 @@ # Contribution guide -We're glad you're interested in contributing Firefish! In this document you will find the information you need to contribute to the project. +We're glad you're interested in contributing Iceshrimp! In this document you will find the information you need to contribute to the project. ## Translation (i18n) -Firefish uses [Weblate](hhttps://hosted.weblate.org/engage/firefish/) for translation and internationalization management. +Iceshrimp uses [Weblate](https://translate.iceshrimp.dev/) for translation and internationalization management. If your language is not listed in Weblate, please open an issue. You can contribute without knowing how to code by helping translate here: -[![Translation status](https://hosted.weblate.org/widgets/firefish/-/287x66-grey.png)](https://hosted.weblate.org/engage/firefish/) +[![Translation status](https://translate.iceshrimp.dev/widgets/iceshrimp/-/287x66-grey.png)](https://translate.iceshrimp.dev/) -[![Translation bars](https://hosted.weblate.org/widgets/firefish/-/multi-auto.svg)](https://hosted.weblate.org/engage/firefish/) +[![Translation bars](https://translate.iceshrimp.dev/widgets/iceshrimp/-/multi-auto.svg)](https://translate.iceshrimp.dev/) -## Roadmap -See [FIREFISH.md](./FIREFISH.md) ## Issues Before creating an issue, please check the following: - To avoid duplication, please search for similar issues before creating a new issue. - Do not use Issues to ask questions or troubleshooting. - Issues should only be used to feature requests, suggestions, and bug tracking. - - Please ask questions or troubleshooting in the [Matrix room](https://matrix.to/#/#firefish:matrix.fedibird.com). + - Please ask questions or troubleshooting in the [Matrix room](https://matrix.to/#/#iceshrimp-dev:161.rocks). > **Warning** > Do not close issues that are about to be resolved. It should remain open until a commit that actually resolves it is merged. diff --git a/COPYING b/COPYING index 27aeb01ac..3d4b38c84 100644 --- a/COPYING +++ b/COPYING @@ -18,7 +18,7 @@ And are distributed under The Apache License, Version 2.0, you should have recei --- -Firefish includes several third-party open-source softwares and software libraries. +Iceshrimp includes several third-party open-source softwares and software libraries. RsaSignature2017 implementation by Transmute Industries Inc License: MIT diff --git a/SECURITY.md b/SECURITY.md index 2f26af6b6..01f04203f 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1,16 +1,11 @@ # Reporting Security Issues -## Minor Security Issues - -If you discover a minor security issue in Firefish, please report it by sending an -email to [kainoa@t1c.dev](mailto:kainoa@t1c.dev). - ## High Security Issues -If you discover a security issue, which is so high risk, that too much is affected by it, please dont send it over unencrypted communication. You can share your PGP keys with us using kainoa@t1c.dev and after we established a secure communication, send it over E-Mail, or message us using matrix' encrypted private messages at @t1c:matrix.fedibird.com or @cleo:tchncs.de +If you discover a security issue, which is so high risk, that too much is affected by it, please dont send it over unencrypted communication. You can share your PGP keys with us using security@iceshrimp.dev and after we established a secure communication, send it over E-Mail, or message us using matrix' encrypted private messages at @zotan:161.rocks This will allow us to assess the risk, and make a fix available before we add a bug report to the Codeberg repository. -Thanks for helping make Firefish safe for everyone. +Thanks for helping make Iceshrimp safe for everyone. diff --git a/chart/Chart.yaml b/chart/Chart.yaml index 8b5832386..cc37ac606 100644 --- a/chart/Chart.yaml +++ b/chart/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 -name: firefish -description: A fun, new, open way to experience social media https://joinfirefish.org +name: iceshrimp +description: A fun, new, open way to experience social media https://iceshrimp.dev # A chart can be either an 'application' or a 'library' chart. # diff --git a/chart/README.md b/chart/README.md index 0833eb9a8..def6b8510 100644 --- a/chart/README.md +++ b/chart/README.md @@ -1,8 +1,8 @@ -# firefish +# iceshrimp ![Version: 0.1.2](https://img.shields.io/badge/Version-0.1.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: rc](https://img.shields.io/badge/AppVersion-rc-informational?style=flat-square) -A fun, new, open way to experience social media https://joinfirefish.org +A fun, new, open way to experience social media https://iceshrimp.dev ## Requirements @@ -21,39 +21,39 @@ A fun, new, open way to experience social media https://joinfirefish.org | autoscaling.maxReplicas | int | `100` | | | autoscaling.minReplicas | int | `1` | | | autoscaling.targetCPUUtilizationPercentage | int | `80` | | -| firefish.allowedPrivateNetworks | list | `[]` | If you want to allow firefish to connect to private ips, enter the cidrs here. | -| firefish.deepl.authKey | string | `""` | | -| firefish.deepl.isPro | bool | `false` | | -| firefish.deepl.managed | bool | `false` | | -| firefish.domain | string | `"firefish.local"` | | -| firefish.isManagedHosting | bool | `true` | | -| firefish.libreTranslate.apiKey | string | `""` | | -| firefish.libreTranslate.apiUrl | string | `""` | | -| firefish.libreTranslate.managed | bool | `false` | | -| firefish.objectStorage.access_key | string | `""` | | -| firefish.objectStorage.access_secret | string | `""` | | -| firefish.objectStorage.baseUrl | string | `""` | | -| firefish.objectStorage.bucket | string | `""` | | -| firefish.objectStorage.endpoint | string | `""` | | -| firefish.objectStorage.managed | bool | `true` | | -| firefish.objectStorage.prefix | string | `"files"` | | -| firefish.objectStorage.region | string | `""` | | -| firefish.reservedUsernames[0] | string | `"root"` | | -| firefish.reservedUsernames[1] | string | `"admin"` | | -| firefish.reservedUsernames[2] | string | `"administrator"` | | -| firefish.reservedUsernames[3] | string | `"me"` | | -| firefish.reservedUsernames[4] | string | `"system"` | | -| firefish.smtp.from_address | string | `"notifications@example.com"` | | -| firefish.smtp.login | string | `""` | | -| firefish.smtp.managed | bool | `true` | | -| firefish.smtp.password | string | `""` | | -| firefish.smtp.port | int | `587` | | -| firefish.smtp.server | string | `"smtp.mailgun.org"` | | -| firefish.smtp.useImplicitSslTls | bool | `false` | | +| iceshrimp.allowedPrivateNetworks | list | `[]` | If you want to allow iceshrimp to connect to private ips, enter the cidrs here. | +| iceshrimp.deepl.authKey | string | `""` | | +| iceshrimp.deepl.isPro | bool | `false` | | +| iceshrimp.deepl.managed | bool | `false` | | +| iceshrimp.domain | string | `"iceshrimp.local"` | | +| iceshrimp.isManagedHosting | bool | `true` | | +| iceshrimp.libreTranslate.apiKey | string | `""` | | +| iceshrimp.libreTranslate.apiUrl | string | `""` | | +| iceshrimp.libreTranslate.managed | bool | `false` | | +| iceshrimp.objectStorage.access_key | string | `""` | | +| iceshrimp.objectStorage.access_secret | string | `""` | | +| iceshrimp.objectStorage.baseUrl | string | `""` | | +| iceshrimp.objectStorage.bucket | string | `""` | | +| iceshrimp.objectStorage.endpoint | string | `""` | | +| iceshrimp.objectStorage.managed | bool | `true` | | +| iceshrimp.objectStorage.prefix | string | `"files"` | | +| iceshrimp.objectStorage.region | string | `""` | | +| iceshrimp.reservedUsernames[0] | string | `"root"` | | +| iceshrimp.reservedUsernames[1] | string | `"admin"` | | +| iceshrimp.reservedUsernames[2] | string | `"administrator"` | | +| iceshrimp.reservedUsernames[3] | string | `"me"` | | +| iceshrimp.reservedUsernames[4] | string | `"system"` | | +| iceshrimp.smtp.from_address | string | `"notifications@example.com"` | | +| iceshrimp.smtp.login | string | `""` | | +| iceshrimp.smtp.managed | bool | `true` | | +| iceshrimp.smtp.password | string | `""` | | +| iceshrimp.smtp.port | int | `587` | | +| iceshrimp.smtp.server | string | `"smtp.mailgun.org"` | | +| iceshrimp.smtp.useImplicitSslTls | bool | `false` | | | elasticsearch | object | `{"auth":{},"enabled":false,"hostname":"","port":9200,"ssl":false}` | https://github.com/bitnami/charts/tree/master/bitnami/elasticsearch#parameters | | fullnameOverride | string | `""` | | | image.pullPolicy | string | `"IfNotPresent"` | | -| image.repository | string | `"docker.io/thatonecalculator/firefish"` | | +| image.repository | string | `"iceshrimp.dev/iceshrimp/iceshrimp"` | | | image.tag | string | `""` | | | imagePullSecrets | list | `[]` | | | ingress.annotations | object | `{}` | | @@ -67,9 +67,9 @@ A fun, new, open way to experience social media https://joinfirefish.org | nodeSelector | object | `{}` | | | podAnnotations | object | `{}` | | | podSecurityContext | object | `{}` | | -| postgresql.auth.database | string | `"firefish_production"` | | +| postgresql.auth.database | string | `"iceshrimp_production"` | | | postgresql.auth.password | string | `""` | | -| postgresql.auth.username | string | `"firefish"` | | +| postgresql.auth.username | string | `"iceshrimp"` | | | postgresql.enabled | bool | `true` | disable if you want to use an existing db; in which case the values below must match those of that external postgres instance | | redis.auth.password | string | `""` | you must set a password; the password generated by the redis chart will be rotated on each upgrade: | | redis.enabled | bool | `true` | | diff --git a/chart/templates/NOTES.txt b/chart/templates/NOTES.txt index e84ee93cf..3fc45a632 100644 --- a/chart/templates/NOTES.txt +++ b/chart/templates/NOTES.txt @@ -6,16 +6,16 @@ {{- end }} {{- end }} {{- else if contains "NodePort" .Values.service.type }} - export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "firefish.fullname" . }}) + export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "iceshrimp.fullname" . }}) export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") echo http://$NODE_IP:$NODE_PORT {{- else if contains "LoadBalancer" .Values.service.type }} NOTE: It may take a few minutes for the LoadBalancer IP to be available. - You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "firefish.fullname" . }}' - export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "firefish.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") + You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "iceshrimp.fullname" . }}' + export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "iceshrimp.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") echo http://$SERVICE_IP:{{ .Values.service.port }} {{- else if contains "ClusterIP" .Values.service.type }} - export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "firefish.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") + export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "iceshrimp.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") export CONTAINER_PORT=$(kubectl get pod --namespace {{ .Release.Namespace }} $POD_NAME -o jsonpath="{.spec.containers[0].ports[0].containerPort}") echo "Visit http://127.0.0.1:8080 to use your application" kubectl --namespace {{ .Release.Namespace }} port-forward $POD_NAME 8080:$CONTAINER_PORT diff --git a/chart/templates/_helpers.tpl b/chart/templates/_helpers.tpl index a7b4b9d32..1ccd45cb1 100644 --- a/chart/templates/_helpers.tpl +++ b/chart/templates/_helpers.tpl @@ -1,7 +1,7 @@ {{/* Expand the name of the chart. */}} -{{- define "firefish.name" -}} +{{- define "iceshrimp.name" -}} {{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} {{- end }} @@ -10,7 +10,7 @@ Create a default fully qualified app name. We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). If release name contains chart name it will be used as a full name. */}} -{{- define "firefish.fullname" -}} +{{- define "iceshrimp.fullname" -}} {{- if .Values.fullnameOverride }} {{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} {{- else }} @@ -26,16 +26,16 @@ If release name contains chart name it will be used as a full name. {{/* Create chart name and version as used by the chart label. */}} -{{- define "firefish.chart" -}} +{{- define "iceshrimp.chart" -}} {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} {{- end }} {{/* Common labels */}} -{{- define "firefish.labels" -}} -helm.sh/chart: {{ include "firefish.chart" . }} -{{ include "firefish.selectorLabels" . }} +{{- define "iceshrimp.labels" -}} +helm.sh/chart: {{ include "iceshrimp.chart" . }} +{{ include "iceshrimp.selectorLabels" . }} {{- if .Chart.AppVersion }} app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} {{- end }} @@ -45,17 +45,17 @@ app.kubernetes.io/managed-by: {{ .Release.Service }} {{/* Selector labels */}} -{{- define "firefish.selectorLabels" -}} -app.kubernetes.io/name: {{ include "firefish.name" . }} +{{- define "iceshrimp.selectorLabels" -}} +app.kubernetes.io/name: {{ include "iceshrimp.name" . }} app.kubernetes.io/instance: {{ .Release.Name }} {{- end }} {{/* Create the name of the service account to use */}} -{{- define "firefish.serviceAccountName" -}} +{{- define "iceshrimp.serviceAccountName" -}} {{- if .Values.serviceAccount.create }} -{{- default (include "firefish.fullname" .) .Values.serviceAccount.name }} +{{- default (include "iceshrimp.fullname" .) .Values.serviceAccount.name }} {{- else }} {{- default "default" .Values.serviceAccount.name }} {{- end }} @@ -65,31 +65,31 @@ Create the name of the service account to use Create a default fully qualified name for dependent services. We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). */}} -{{- define "firefish.elasticsearch.fullname" -}} +{{- define "iceshrimp.elasticsearch.fullname" -}} {{- printf "%s-%s" .Release.Name "elasticsearch" | trunc 63 | trimSuffix "-" -}} {{- end -}} -{{- define "firefish.redis.fullname" -}} +{{- define "iceshrimp.redis.fullname" -}} {{- printf "%s-%s" .Release.Name "redis" | trunc 63 | trimSuffix "-" -}} {{- end -}} -{{- define "firefish.postgresql.fullname" -}} +{{- define "iceshrimp.postgresql.fullname" -}} {{- printf "%s-%s" .Release.Name "postgresql" | trunc 63 | trimSuffix "-" -}} {{- end -}} {{/* config/default.yml content */}} -{{- define "firefish.configDir.default.yml" -}} +{{- define "iceshrimp.configDir.default.yml" -}} #โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ” -# Firefish configuration +# iceshrimp configuration #โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ”โ” # โ”Œโ”€โ”€โ”€โ”€โ”€โ” #โ”€โ”€โ”€โ”˜ URL โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ # Final accessible URL seen by a user. -url: "https://{{ .Values.firefish.domain }}/" +url: "https://{{ .Values.iceshrimp.domain }}/" # ONCE YOU HAVE STARTED THE INSTANCE, DO NOT CHANGE THE # URL SETTINGS AFTER THAT! @@ -118,7 +118,7 @@ port: 3000 db: {{- if .Values.postgresql.enabled }} - host: {{ template "firefish.postgresql.fullname" . }} + host: {{ template "iceshrimp.postgresql.fullname" . }} port: '5432' {{- else }} host: {{ .Values.postgresql.postgresqlHostname }} @@ -146,7 +146,7 @@ db: redis: {{- if .Values.redis.enabled }} - host: {{ template "firefish.redis.fullname" . }}-master + host: {{ template "iceshrimp.redis.fullname" . }}-master {{- else }} host: {{ required "When the redis chart is disabled .Values.redis.hostname is required" .Values.redis.hostname }} {{- end }} @@ -218,7 +218,7 @@ id: 'aid' # Reserved usernames that only the administrator can register with reservedUsernames: -{{ .Values.firefish.reservedUsernames | toYaml }} +{{ .Values.iceshrimp.reservedUsernames | toYaml }} # Whether disable HSTS #disableHsts: true @@ -266,7 +266,7 @@ reservedUsernames: #proxyRemoteFiles: true allowedPrivateNetworks: -{{ .Values.firefish.allowedPrivateNetworks | toYaml }} +{{ .Values.iceshrimp.allowedPrivateNetworks | toYaml }} # TWA #twa: @@ -286,34 +286,34 @@ allowedPrivateNetworks: # If you mess this up, that's on you, you've been warned... #maxUserSignups: 100 -isManagedHosting: {{ .Values.firefish.isManagedHosting }} +isManagedHosting: {{ .Values.iceshrimp.isManagedHosting }} deepl: - managed: {{ .Values.firefish.deepl.managed }} - authKey: {{ .Values.firefish.deepl.authKey | quote}} - isPro: {{ .Values.firefish.deepl.isPro }} + managed: {{ .Values.iceshrimp.deepl.managed }} + authKey: {{ .Values.iceshrimp.deepl.authKey | quote}} + isPro: {{ .Values.iceshrimp.deepl.isPro }} libreTranslate: - managed: {{ .Values.firefish.libreTranslate.managed }} - apiUrl: {{ .Values.firefish.libreTranslate.apiUrl | quote }} - apiKey: {{ .Values.firefish.libreTranslate.apiKey | quote }} + managed: {{ .Values.iceshrimp.libreTranslate.managed }} + apiUrl: {{ .Values.iceshrimp.libreTranslate.apiUrl | quote }} + apiKey: {{ .Values.iceshrimp.libreTranslate.apiKey | quote }} email: - managed: {{ .Values.firefish.smtp.managed }} - address: {{ .Values.firefish.smtp.from_address | quote }} - host: {{ .Values.firefish.smtp.server | quote }} - port: {{ .Values.firefish.smtp.port }} - user: {{ .Values.firefish.smtp.login | quote }} - pass: {{ .Values.firefish.smtp.password | quote }} - useImplicitSslTls: {{ .Values.firefish.smtp.useImplicitSslTls }} + managed: {{ .Values.iceshrimp.smtp.managed }} + address: {{ .Values.iceshrimp.smtp.from_address | quote }} + host: {{ .Values.iceshrimp.smtp.server | quote }} + port: {{ .Values.iceshrimp.smtp.port }} + user: {{ .Values.iceshrimp.smtp.login | quote }} + pass: {{ .Values.iceshrimp.smtp.password | quote }} + useImplicitSslTls: {{ .Values.iceshrimp.smtp.useImplicitSslTls }} objectStorage: - managed: {{ .Values.firefish.objectStorage.managed }} - baseUrl: {{ .Values.firefish.objectStorage.baseUrl | quote }} - bucket: {{ .Values.firefish.objectStorage.bucket | quote }} - prefix: {{ .Values.firefish.objectStorage.prefix | quote }} - endpoint: {{ .Values.firefish.objectStorage.endpoint | quote }} - region: {{ .Values.firefish.objectStorage.region | quote }} - accessKey: {{ .Values.firefish.objectStorage.access_key | quote }} - secretKey: {{ .Values.firefish.objectStorage.access_secret | quote }} + managed: {{ .Values.iceshrimp.objectStorage.managed }} + baseUrl: {{ .Values.iceshrimp.objectStorage.baseUrl | quote }} + bucket: {{ .Values.iceshrimp.objectStorage.bucket | quote }} + prefix: {{ .Values.iceshrimp.objectStorage.prefix | quote }} + endpoint: {{ .Values.iceshrimp.objectStorage.endpoint | quote }} + region: {{ .Values.iceshrimp.objectStorage.region | quote }} + accessKey: {{ .Values.iceshrimp.objectStorage.access_key | quote }} + secretKey: {{ .Values.iceshrimp.objectStorage.access_secret | quote }} useSsl: true connnectOverProxy: false setPublicReadOnUpload: true diff --git a/chart/templates/deployment.yaml b/chart/templates/deployment.yaml index ca6316763..136e032de 100644 --- a/chart/templates/deployment.yaml +++ b/chart/templates/deployment.yaml @@ -1,16 +1,16 @@ apiVersion: apps/v1 kind: Deployment metadata: - name: {{ include "firefish.fullname" . }} + name: {{ include "iceshrimp.fullname" . }} labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} spec: {{- if not .Values.autoscaling.enabled }} replicas: {{ .Values.replicaCount }} {{- end }} selector: matchLabels: - {{- include "firefish.selectorLabels" . | nindent 6 }} + {{- include "iceshrimp.selectorLabels" . | nindent 6 }} template: metadata: annotations: @@ -19,19 +19,19 @@ spec: {{- toYaml . | nindent 8 }} {{- end }} labels: - {{- include "firefish.selectorLabels" . | nindent 8 }} + {{- include "iceshrimp.selectorLabels" . | nindent 8 }} spec: {{- with .Values.imagePullSecrets }} imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} - serviceAccountName: {{ include "firefish.serviceAccountName" . }} + serviceAccountName: {{ include "iceshrimp.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} volumes: - name: config-volume secret: - secretName: {{ template "firefish.fullname" . }}-config + secretName: {{ template "iceshrimp.fullname" . }}-config containers: - name: {{ .Chart.Name }} securityContext: @@ -47,7 +47,7 @@ spec: value: "production" volumeMounts: - name: config-volume - mountPath: /firefish/.config + mountPath: /iceshrimp/.config ports: - name: http containerPort: 3000 diff --git a/chart/templates/hpa.yaml b/chart/templates/hpa.yaml index db19534a8..6fe0f89ab 100644 --- a/chart/templates/hpa.yaml +++ b/chart/templates/hpa.yaml @@ -2,14 +2,14 @@ apiVersion: autoscaling/v2beta1 kind: HorizontalPodAutoscaler metadata: - name: {{ include "firefish.fullname" . }} + name: {{ include "iceshrimp.fullname" . }} labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} spec: scaleTargetRef: apiVersion: apps/v1 kind: Deployment - name: {{ include "firefish.fullname" . }} + name: {{ include "iceshrimp.fullname" . }} minReplicas: {{ .Values.autoscaling.minReplicas }} maxReplicas: {{ .Values.autoscaling.maxReplicas }} metrics: diff --git a/chart/templates/ingress.yaml b/chart/templates/ingress.yaml index 65caa43e8..74d87b78d 100644 --- a/chart/templates/ingress.yaml +++ b/chart/templates/ingress.yaml @@ -1,5 +1,5 @@ {{- if .Values.ingress.enabled -}} -{{- $fullName := include "firefish.fullname" . -}} +{{- $fullName := include "iceshrimp.fullname" . -}} {{- $svcPort := .Values.service.port -}} {{- if and .Values.ingress.className (not (semverCompare ">=1.18-0" .Capabilities.KubeVersion.GitVersion)) }} {{- if not (hasKey .Values.ingress.annotations "kubernetes.io/ingress.class") }} @@ -17,7 +17,7 @@ kind: Ingress metadata: name: {{ $fullName }} labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} {{- with .Values.ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/chart/templates/job-db-migrate.yaml b/chart/templates/job-db-migrate.yaml index 1aedeab5b..0ecd6d45a 100644 --- a/chart/templates/job-db-migrate.yaml +++ b/chart/templates/job-db-migrate.yaml @@ -1,9 +1,9 @@ apiVersion: batch/v1 kind: Job metadata: - name: {{ include "firefish.fullname" . }}-db-migrate + name: {{ include "iceshrimp.fullname" . }}-db-migrate labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} annotations: "helm.sh/hook": post-install,pre-upgrade "helm.sh/hook-delete-policy": before-hook-creation,hook-succeeded @@ -11,7 +11,7 @@ metadata: spec: template: metadata: - name: {{ include "firefish.fullname" . }}-db-migrate + name: {{ include "iceshrimp.fullname" . }}-db-migrate {{- with .Values.podAnnotations }} annotations: {{- toYaml . | nindent 8 }} @@ -22,13 +22,13 @@ spec: imagePullSecrets: {{- toYaml . | nindent 8 }} {{- end }} - serviceAccountName: {{ include "firefish.serviceAccountName" . }} + serviceAccountName: {{ include "iceshrimp.serviceAccountName" . }} securityContext: {{- toYaml .Values.podSecurityContext | nindent 8 }} volumes: - name: config-volume secret: - secretName: {{ template "firefish.fullname" . }}-config + secretName: {{ template "iceshrimp.fullname" . }}-config containers: - name: {{ .Chart.Name }} securityContext: @@ -44,7 +44,7 @@ spec: value: "production" volumeMounts: - name: config-volume - mountPath: /firefish/.config + mountPath: /iceshrimp/.config {{- with .Values.nodeSelector }} nodeSelector: {{- toYaml . | nindent 8 }} diff --git a/chart/templates/secret-config.yaml b/chart/templates/secret-config.yaml index 9f683cfcd..b85942ecf 100644 --- a/chart/templates/secret-config.yaml +++ b/chart/templates/secret-config.yaml @@ -1,9 +1,9 @@ apiVersion: v1 kind: Secret metadata: - name: {{ template "firefish.fullname" . }}-config + name: {{ template "iceshrimp.fullname" . }}-config labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} type: Opaque data: - default.yml: {{ include "firefish.configDir.default.yml" . | b64enc }} + default.yml: {{ include "iceshrimp.configDir.default.yml" . | b64enc }} diff --git a/chart/templates/service.yaml b/chart/templates/service.yaml index f49d9cd5d..fb7317c3a 100644 --- a/chart/templates/service.yaml +++ b/chart/templates/service.yaml @@ -1,9 +1,9 @@ apiVersion: v1 kind: Service metadata: - name: {{ include "firefish.fullname" . }} + name: {{ include "iceshrimp.fullname" . }} labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} spec: type: {{ .Values.service.type }} ports: @@ -12,4 +12,4 @@ spec: protocol: TCP name: http selector: - {{- include "firefish.selectorLabels" . | nindent 4 }} + {{- include "iceshrimp.selectorLabels" . | nindent 4 }} diff --git a/chart/templates/serviceaccount.yaml b/chart/templates/serviceaccount.yaml index d8db3a3ae..b2458a287 100644 --- a/chart/templates/serviceaccount.yaml +++ b/chart/templates/serviceaccount.yaml @@ -2,9 +2,9 @@ apiVersion: v1 kind: ServiceAccount metadata: - name: {{ include "firefish.serviceAccountName" . }} + name: {{ include "iceshrimp.serviceAccountName" . }} labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} {{- with .Values.serviceAccount.annotations }} annotations: {{- toYaml . | nindent 4 }} diff --git a/chart/templates/tests/test-connection.yaml b/chart/templates/tests/test-connection.yaml index 7abe03611..baf0a01eb 100644 --- a/chart/templates/tests/test-connection.yaml +++ b/chart/templates/tests/test-connection.yaml @@ -1,9 +1,9 @@ apiVersion: v1 kind: Pod metadata: - name: "{{ include "firefish.fullname" . }}-test-connection" + name: "{{ include "iceshrimp.fullname" . }}-test-connection" labels: - {{- include "firefish.labels" . | nindent 4 }} + {{- include "iceshrimp.labels" . | nindent 4 }} annotations: "helm.sh/hook": test spec: @@ -11,5 +11,5 @@ spec: - name: wget image: busybox command: ['wget'] - args: ['{{ include "firefish.fullname" . }}:{{ .Values.service.port }}'] + args: ['{{ include "iceshrimp.fullname" . }}:{{ .Values.service.port }}'] restartPolicy: Never diff --git a/chart/values.yaml b/chart/values.yaml index 3bb050441..1470f7aef 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -1,18 +1,18 @@ -# Default values for firefish. +# Default values for iceshrimp. # This is a YAML-formatted file. # Declare variables to be passed into your templates. replicaCount: 1 image: - repository: docker.io/thatonecalculator/firefish + repository: docker.io/thatonecalculator/iceshrimp pullPolicy: IfNotPresent # Overrides the image tag whose default is the chart appVersion. tag: "" -firefish: +iceshrimp: isManagedHosting: true - domain: firefish.local + domain: iceshrimp.local deepl: managed: false @@ -43,7 +43,7 @@ firefish: endpoint: "" # e.g. "nyc3.digitaloceanspaces.com:443" region: "" # e.g. "nyc3" - # -- If you want to allow firefish to connect to private ips, enter the cidrs here. + # -- If you want to allow iceshrimp to connect to private ips, enter the cidrs here. allowedPrivateNetworks: [] # - "10.0.0.0/8" @@ -62,8 +62,8 @@ postgresql: # postgresqlHostname: preexisting-postgresql # postgresqlPort: 5432 auth: - database: firefish_production - username: firefish + database: iceshrimp_production + username: iceshrimp # you must set a password; the password generated by the postgresql chart will # be rotated on each upgrade: # https://github.com/bitnami/charts/tree/master/bitnami/postgresql#upgrade diff --git a/cliff.toml b/cliff.toml index 986ce68f2..c70e430d6 100644 --- a/cliff.toml +++ b/cliff.toml @@ -4,7 +4,7 @@ # changelog header header = """ # Changelog\n -All changes from v13.0.0 onwards, for a list of differences read FIREFISH.md\n +All changes from v13.0.0 onwards, for a list of differences read CHANGES_FROM_UPSTREAM.md\n """ # template for the changelog body # https://tera.netlify.app/docs/#introduction diff --git a/custom/assets/LICENSE b/custom/assets/LICENSE index cb57aef95..79f5e9541 100644 --- a/custom/assets/LICENSE +++ b/custom/assets/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 Firefish +Copyright 2023 The Iceshrimp contributors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/dev/docker-compose.yml.example b/dev/docker-compose.yml.example index 21779a57b..5858cbd28 100644 --- a/dev/docker-compose.yml.example +++ b/dev/docker-compose.yml.example @@ -2,9 +2,9 @@ version: "3" services: web: - image: docker.io/thatonecalculator/firefish + image: iceshrimp.dev/iceshrimp/iceshrimp:dev build: .. - container_name: firefish_web + container_name: iceshrimp_web restart: always depends_on: - db @@ -16,12 +16,12 @@ services: - network # - web volumes: - - ../files:/firefish/files - - ../.config:/firefish/.config:ro + - ../files:/iceshrimp/files + - ../.config:/iceshrimp/.config:ro redis: restart: always - container_name: firefish_redis + container_name: iceshrimp_redis image: docker.io/redis:7.0-alpine networks: - network @@ -31,7 +31,7 @@ services: db: restart: always image: docker.io/postgres:12.2-alpine - container_name: firefish_db + container_name: iceshrimp_db networks: - network env_file: diff --git a/docs/api-doc.md b/docs/api-doc.md index e4cc54059..764fd9227 100644 --- a/docs/api-doc.md +++ b/docs/api-doc.md @@ -1,5 +1,5 @@ # API Documentation -You can find interactive API documentation at any Firefish instance. https://firefish.social/api-doc +You can find interactive API documentation at any Iceshrimp instance. https://iceshrimp.social/api-doc You can also find auto-generated documentation for iceshrimp-js [here](../packages/iceshrimp-js/markdown/iceshrimp-js.md). diff --git a/docs/development.md b/docs/development.md index 31e6bf999..c5d61f091 100644 --- a/docs/development.md +++ b/docs/development.md @@ -1,7 +1,7 @@ -# ๐ŸŒŽ Firefish Developer Docs +# ๐ŸŒŽ Iceshrimp Developer Docs ## Nix Dev Environment -The Firefish repo comes with a Nix-based shell environment to help make development as easy as possible! +The Iceshrimp repo comes with a Nix-based shell environment to help make development as easy as possible! Please note, however, that this environment will not work on Windows outside of a WSL2 environment. @@ -10,12 +10,12 @@ Please note, however, that this environment will not work on Windows outside of - Installed the [Nix Package Manager](https://nixos.org/download.html) (use the comman on their website) - Installed [direnv](https://direnv.net/docs/installation.html) and added its hook to your shell. (package manager) -Once the repo is cloned to your computer, follow these next few steps inside the Firefish folder: +Once the repo is cloned to your computer, follow these next few steps inside the Iceshrimp folder: - Run `direnv allow`. This will build the environment and install all needed tools. - Run `install-deps`, then `prepare-config`, to install the node dependencies and prepare the needed config files. -- In a second terminal, run `devenv up`. This will spawn a **Redis** server, a **Postgres** server, and the **Firefish** server in dev mode. -- Once you see the Firefish banner printed in your second terminal, run `migrate` in the first. +- In a second terminal, run `devenv up`. This will spawn a **Redis** server, a **Postgres** server, and the **Iceshrimp** server in dev mode. +- Once you see the Iceshrimp banner printed in your second terminal, run `migrate` in the first. - Once migrations finish, open http://localhost:3000 in your web browser. - You should now see the admin user creation screen! @@ -40,7 +40,7 @@ delete `flake.lock`, or better, run `nix flake update --extra-experimental-featu after that, run `direnv rebuild` if there are any errors, you might have to change `flake.nix` -(because the available options can change between versions - consider getting support in [the matrix channel](https://matrix.to/#/#firefish:matrix.fedibird.com)) +(because the available options can change between versions - consider getting support in [the matrix channel](https://matrix.to/#/%23iceshrimp-dev:161.rocks)) ### after changing a node version in my case, i had to change the node version from 19, to 18 @@ -66,18 +66,18 @@ devenv up may take a looong time. (some say this is fake news, maybe it was bad do not get spooked by this error: ``` -> firefish@14.0.0-dev32 start /mnt/.../firefish +> iceshrimp@14.0.0-dev32 start /mnt/.../iceshrimp > pnpm --filter backend run start -> backend@ start /mnt/.../firefish/packages/backend +> backend@ start /mnt/.../iceshrimp/packages/backend > pnpm node ./built/index.js node:internal/modules/cjs/loader:1078 throw err; ^ -Error: Cannot find module '/mnt/.../firefish/packages/backend/built/index.js' +Error: Cannot find module '/mnt/.../iceshrimp/packages/backend/built/index.js' at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15) at Module._load (node:internal/modules/cjs/loader:920:27) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) @@ -88,7 +88,7 @@ Error: Cannot find module '/mnt/.../firefish/packages/backend/built/index.js' Node.js v18.16.0 undefined -/mnt/.../firefish/packages/backend: +/mnt/.../iceshrimp/packages/backend: โ€‰ERR_PNPM_RECURSIVE_RUN_FIRST_FAILโ€‰ backend@ start: `pnpm node ./built/index.js` Exit status 1 โ€‰ELIFECYCLEโ€‰ Command failed with exit code 1. @@ -97,7 +97,7 @@ Exit status 1 the script is designed to constantly try to start the server, while the build is still running. this just means that the build isn't finished yet. -at some point you should see a banner that says "Firefish" in big letters - +at some point you should see a banner that says "Iceshrimp" in big letters - then you're good to go and can run `migrate` (in another terminal)! if you don't see the banner, diff --git a/docs/docker.md b/docs/docker.md index b8a243a38..179c60aa6 100644 --- a/docs/docker.md +++ b/docs/docker.md @@ -1,14 +1,14 @@ -# ๐Ÿณ Running a Firefish server with Docker +# ๐Ÿณ Running a Iceshrimp server with Docker ## Pre-built docker container -[thatonecalculator/firefish](https://hub.docker.com/r/thatonecalculator/firefish) +[iceshrimp/iceshrimp](iceshrimp.dev/iceshrimp/iceshrimp) ## `docker-compose` There is a `docker-compose.yml` in the root of the project that you can use to build the container from source - .config/docker.env (**db config settings**) -- .config/default.yml (**firefish server settings**) +- .config/default.yml (**Iceshrimp server settings**) ## Configuring @@ -21,22 +21,22 @@ Rename the files: then edit them according to your environment. You can configure `docker.env` with anything you like, but you will have to pay attention to the `default.yml` file: - `url` should be set to the URL you will be hosting the web interface for the server at. -- `host`, `db`, `user`, `pass` will have to be configured in the `PostgreSQL configuration` section - `host` is the name of the postgres container (eg: *firefish_db_1*), and the others should match your `docker.env`. -- `host`will need to be configured in the *Redis configuration* section - it is the name of the redis container (eg: *firefish_redis_1*) +- `host`, `db`, `user`, `pass` will have to be configured in the `PostgreSQL configuration` section - `host` is the name of the postgres container (eg: *iceshrimp_db_1*), and the others should match your `docker.env`. +- `host`will need to be configured in the *Redis configuration* section - it is the name of the redis container (eg: *iceshrimp_redis_1*) - `auth` will need to be configured in the *Sonic* section - cannot be the default `SecretPassword` Everything else can be left as-is. ## Running docker-compose -The [prebuilt container for firefish](https://hub.docker.com/r/thatonecalculator/firefish) is fairly large, and may take a few minutes to download and extract using docker. +The [prebuilt container for iceshrimp](https://iceshrimp.dev/iceshrimp/-/packages/container/iceshrimp/latest) is fairly large, and may take a few minutes to download and extract using docker. Copy `docker-compose.yml` and the `config/` to a directory, then run the **docker-compose** command: `docker-compose up -d`. -NOTE: This will take some time to come fully online, even after download and extracting the container images, and it may emit some error messages before completing successfully. Specifically, the `db` container needs to initialize and so isn't available to the `web` container right away. Only once the `db` container comes online does the `web` container start building and initializing the firefish tables. +NOTE: This will take some time to come fully online, even after download and extracting the container images, and it may emit some error messages before completing successfully. Specifically, the `db` container needs to initialize and so isn't available to the `web` container right away. Only once the `db` container comes online does the `web` container start building and initializing the Iceshrimp tables. -Once the server is up you can use a web browser to access the web interface at `http://serverip:3000` (where `serverip` is the IP of the server you are running the firefish server on). +Once the server is up you can use a web browser to access the web interface at `http://serverip:3000` (where `serverip` is the IP of the server you are running the Iceshrimp server on). ## Docker for development diff --git a/docs/kubernetes.md b/docs/kubernetes.md index 5ec6b46ad..2a0e2e037 100644 --- a/docs/kubernetes.md +++ b/docs/kubernetes.md @@ -1,7 +1,7 @@ -# Running a Firefish server with Kubernetes and Helm +# Running a iceshrimp server with Kubernetes and Helm This is a [Helm](https://helm.sh/) chart directory in the root of the project -that you can use to deploy firefish to a Kubernetes cluster +that you can use to deploy iceshrimp to a Kubernetes cluster ## Deployment @@ -17,29 +17,29 @@ helm dependency list $dir 2> /dev/null | tail +2 | head -n -1 | awk '{ print "he cd ../ ``` -3. Create the firefish helm release (also used to update existing deployment): +3. Create the iceshrimp helm release (also used to update existing deployment): ```shell helm upgrade \ --install \ - --namespace firefish \ + --namespace iceshrimp \ --create-namespace \ - firefish chart/ \ + iceshrimp chart/ \ -f .config/helm_values.yml ``` -4. Watch your firefish server spin up: +4. Watch your iceshrimp server spin up: ```shell -kubectl -n firefish get po -w +kubectl -n iceshrimp get po -w ``` 5. Initial the admin user and managed config: ```shell -export firefish_USERNAME="my_desired_admin_handle" && \ -export firefish_PASSWORD="myDesiredInitialPassword" && \ -export firefish_HOST="firefish.example.com" && \ -export firefish_TOKEN=$(curl -X POST https://$firefish_HOST/api/admin/accounts/create -H "Content-Type: application/json" -d "{ \"username\":\"$firefish_USERNAME\", \"password\":\"$firefish_PASSWORD\" }" | jq -r '.token') && \ -echo "Save this token: ${firefish_TOKEN}" && \ -curl -X POST -H "Authorization: Bearer $firefish_TOKEN" https://$firefish_HOST/api/admin/accounts/hosted +export iceshrimp_USERNAME="my_desired_admin_handle" && \ +export iceshrimp_PASSWORD="myDesiredInitialPassword" && \ +export iceshrimp_HOST="iceshrimp.example.com" && \ +export iceshrimp_TOKEN=$(curl -X POST https://$iceshrimp_HOST/api/admin/accounts/create -H "Content-Type: application/json" -d "{ \"username\":\"$iceshrimp_USERNAME\", \"password\":\"$iceshrimp_PASSWORD\" }" | jq -r '.token') && \ +echo "Save this token: ${iceshrimp_TOKEN}" && \ +curl -X POST -H "Authorization: Bearer $iceshrimp_TOKEN" https://$iceshrimp_HOST/api/admin/accounts/hosted ``` 6. Enjoy! diff --git a/docs/migrate.md b/docs/migrate.md index 4420a74e7..9709c1cf1 100644 --- a/docs/migrate.md +++ b/docs/migrate.md @@ -1,4 +1,4 @@ -# ๐Ÿšš Migrating from Misskey/FoundKey to Firefish +# ๐Ÿšš Migrating from Misskey/FoundKey to Iceshrimp All the guides below assume you're starting in the root of the repo directory. @@ -14,8 +14,8 @@ Tested with Misskey v13.11.3. If your Misskey v13 is older, we recommend updating your Misskey to v13.11.3. ```sh -wget -O mkv13.patch https://codeberg.org/firefish/firefish/raw/branch/develop/docs/mkv13.patch -wget -O mkv13_restore.patch https://codeberg.org/firefish/firefish/raw/branch/develop/docs/mkv13_restore.patch +wget -O mkv13.patch https://iceshrimp.dev/iceshrimp/iceshrimp/raw/branch/dev/docs/mkv13.patch +wget -O mkv13_restore.patch https://iceshrimp.dev/iceshrimp/iceshrimp/raw/branch/dev/docs/mkv13_restore.patch git apply mkv13.patch mkv13_restore.patch cd packages/backend @@ -27,13 +27,13 @@ for i in $(seq 1 $NUM_MIGRATIONS); do pnpm typeorm migration:revert -d ormconfig cd ../../ -git remote set-url origin https://codeberg.org/firefish/firefish.git +git remote set-url origin https://iceshrimp.dev/iceshrimp/iceshrimp.git git fetch origin git stash push rm -rf fluent-emojis misskey-assets git switch main # or beta or develop git pull --ff -wget -O renote_muting.patch https://codeberg.org/firefish/firefish/raw/branch/develop/docs/renote_muting.patch +wget -O renote_muting.patch https://iceshrimp.dev/iceshrimp/iceshrimp/raw/branch/dev/docs/renote_muting.patch git apply renote_muting.patch pnpm install @@ -60,16 +60,16 @@ ALTER TABLE "instance" ADD COLUMN "latestStatus" character varying(512); ALTER TABLE "instance" ADD COLUMN "lastCommunicatedAt" date; ``` -then quit with `\q`, and restart Firefish. +then quit with `\q`, and restart Iceshrimp. Note: Ignore errors of `column "xxx" of relation "xxx" already exists`. -If no other errors happened, your Firefish is ready to launch! +If no other errors happened, your Iceshrimp is ready to launch! ## Misskey v12.119 and before ```sh -git remote set-url origin https://codeberg.org/firefish/firefish.git +git remote set-url origin https://iceshrimp.dev/iceshrimp/iceshrimp.git git fetch git checkout main # or beta or develop git pull --ff @@ -81,7 +81,7 @@ NODE_ENV=production pnpm run migrate ## FoundKey ```sh -wget -O fk.patch https://codeberg.org/firefish/firefish/raw/branch/develop/docs/fk.patch +wget -O fk.patch https://iceshrimp.dev/iceshrimp/iceshrimp/raw/branch/dev/docs/fk.patch git apply fk.patch cd packages/backend @@ -92,9 +92,9 @@ for i in $(seq 1 $NUM_MIGRATIONS); do npx typeorm migration:revert -d ormconfig.js done -git remote set-url origin https://codeberg.org/firefish/firefish.git +git remote set-url origin https://iceshrimp.dev/iceshrimp/iceshrimp.git git fetch -git checkout main # or beta or develop +git checkout main # or dev git pull --ff NODE_ENV=production pnpm run migrate @@ -103,4 +103,4 @@ NODE_ENV=production pnpm run migrate ## Reverse -You ***cannot*** migrate back to Misskey from Firefish due to re-hashing passwords on signin with argon2. You can migrate from Calckey to FoundKey, although this is not recommended due to FoundKey being end-of-life, and may have some problems with alt-text. +You ***cannot*** migrate back to Misskey from Iceshrimp due to re-hashing passwords on signin with argon2. You can migrate from Iceshrimp to FoundKey, although this is not recommended due to FoundKey being end-of-life, and may have some problems with alt-text. diff --git a/flake.nix b/flake.nix index 4352f49b7..3aabd6219 100644 --- a/flake.nix +++ b/flake.nix @@ -1,5 +1,5 @@ { - description = "Firefish development flake"; + description = "Iceshrimp development flake"; inputs = { nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable"; diff --git a/packages/README.md b/packages/README.md index af3990fe4..bbca57472 100644 --- a/packages/README.md +++ b/packages/README.md @@ -1,6 +1,6 @@ # ๐Ÿ“ฆ Packages -This directory contains all of the packages Firefish uses. +This directory contains all of the packages Iceshrimp uses. - `backend`: Main backend code written in TypeScript for NodeJS - `backend/native-utils`: Backend code written in Rust, bound to NodeJS by [NAPI-RS](https://napi.rs/) diff --git a/packages/backend/assets/LICENSE b/packages/backend/assets/LICENSE index cb57aef95..79f5e9541 100644 --- a/packages/backend/assets/LICENSE +++ b/packages/backend/assets/LICENSE @@ -1,4 +1,4 @@ -Copyright 2023 Firefish +Copyright 2023 The Iceshrimp contributors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/packages/backend/assets/splash.svg b/packages/backend/assets/splash.svg index 4a6662720..5e66d76cb 100644 --- a/packages/backend/assets/splash.svg +++ b/packages/backend/assets/splash.svg @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb20576e78aac55ccea0d64dfba965b71eab4d57ed88ce3bf3813b1b68eb4152 -size 5077 +oid sha256:9c8e266796268db21997cf1b548bd5e4062dcb224fa933045b5176136fcc170e +size 5122 diff --git a/packages/backend/native-utils/src/mastodon_api.rs b/packages/backend/native-utils/src/mastodon_api.rs index 150a76245..a73dfae83 100644 --- a/packages/backend/native-utils/src/mastodon_api.rs +++ b/packages/backend/native-utils/src/mastodon_api.rs @@ -8,7 +8,7 @@ static CHAR_COLLECTION: &str = "0123456789abcdefghijklmnopqrstuvwxyz"; #[napi] pub enum IdConvertType { MastodonId, - FirefishId, + IceshrimpId, } #[napi] @@ -23,7 +23,7 @@ pub fn convert_id(in_id: String, id_convert_type: IdConvertType) -> napi::Result Ok(out.to_string()) } - FirefishId => { + IceshrimpId => { let mut input: i128 = match in_id.parse() { Ok(s) => s, Err(_) => { diff --git a/packages/backend/src/config/load.ts b/packages/backend/src/config/load.ts index 0d40fccae..38bee03bc 100644 --- a/packages/backend/src/config/load.ts +++ b/packages/backend/src/config/load.ts @@ -53,7 +53,7 @@ export default function load() { mixin.apiUrl = `${mixin.scheme}://${mixin.host}/api`; mixin.authUrl = `${mixin.scheme}://${mixin.host}/auth`; mixin.driveUrl = `${mixin.scheme}://${mixin.host}/files`; - mixin.userAgent = `Firefish/${meta.version} (${config.url})`; + mixin.userAgent = `Iceshrimp/${meta.version} (${config.url})`; mixin.clientEntry = clientManifest["src/init.ts"]; if (!config.redis.prefix) config.redis.prefix = mixin.hostname; diff --git a/packages/backend/src/misc/fetch-meta.ts b/packages/backend/src/misc/fetch-meta.ts index b3a5e30ae..a94f73f6f 100644 --- a/packages/backend/src/misc/fetch-meta.ts +++ b/packages/backend/src/misc/fetch-meta.ts @@ -18,8 +18,8 @@ export function metaToPugArgs(meta: Meta): object { return { img: meta.bannerUrl, - title: meta.name || "Firefish", - instanceName: meta.name || "Firefish", + title: meta.name || "Iceshrimp", + instanceName: meta.name || "Iceshrimp", desc: meta.description, icon: meta.iconUrl, splashIcon: splashIconUrl, diff --git a/packages/backend/src/models/entities/meta.ts b/packages/backend/src/models/entities/meta.ts index d57c2ac63..530c1c677 100644 --- a/packages/backend/src/models/entities/meta.ts +++ b/packages/backend/src/models/entities/meta.ts @@ -436,14 +436,14 @@ export class Meta { @Column("varchar", { length: 512, - default: "https://codeberg.org/firefish/firefish", + default: "https://iceshrimp.dev/iceshrimp/iceshrimp", nullable: false, }) public repositoryUrl: string; @Column("varchar", { length: 512, - default: "https://codeberg.org/firefish/firefish/issues/new", + default: "https://iceshrimp.dev/iceshrimp/iceshrimp/issues/new", nullable: true, }) public feedbackUrl: string | null; diff --git a/packages/backend/src/models/schema/federation-instance.ts b/packages/backend/src/models/schema/federation-instance.ts index 868510c46..a5daec819 100644 --- a/packages/backend/src/models/schema/federation-instance.ts +++ b/packages/backend/src/models/schema/federation-instance.ts @@ -19,7 +19,7 @@ export const packedFederationInstanceSchema = { type: "string", optional: false, nullable: false, - example: "firefish.example.com", + example: "iceshrimp.example.com", }, accountDomain: { type: "string", @@ -83,7 +83,7 @@ export const packedFederationInstanceSchema = { type: "string", optional: false, nullable: true, - example: "firefish", + example: "iceshrimp", }, softwareVersion: { type: "string", diff --git a/packages/backend/src/models/schema/hashtag.ts b/packages/backend/src/models/schema/hashtag.ts index 479ab88f9..0f8be622d 100644 --- a/packages/backend/src/models/schema/hashtag.ts +++ b/packages/backend/src/models/schema/hashtag.ts @@ -5,7 +5,7 @@ export const packedHashtagSchema = { type: "string", optional: false, nullable: false, - example: "firefish", + example: "iceshrimp", }, mentionedUsersCount: { type: "number", diff --git a/packages/backend/src/queue/processors/webhook-deliver.ts b/packages/backend/src/queue/processors/webhook-deliver.ts index 286b401ba..904291da2 100644 --- a/packages/backend/src/queue/processors/webhook-deliver.ts +++ b/packages/backend/src/queue/processors/webhook-deliver.ts @@ -16,10 +16,10 @@ export default async (job: Bull.Job) => { url: job.data.to, method: "POST", headers: { - "User-Agent": "Firefish-Hooks", - "X-Firefish-Host": config.host, - "X-Firefish-Hook-Id": job.data.webhookId, - "X-Firefish-Hook-Secret": job.data.secret, + "User-Agent": "Iceshrimp-Hooks", + "X-Iceshrimp-Host": config.host, + "X-Iceshrimp-Hook-Id": job.data.webhookId, + "X-Iceshrimp-Hook-Secret": job.data.secret, "Content-Type": "application/json", }, body: JSON.stringify({ diff --git a/packages/backend/src/remote/activitypub/models/image.ts b/packages/backend/src/remote/activitypub/models/image.ts index 67652d57d..7152a2573 100644 --- a/packages/backend/src/remote/activitypub/models/image.ts +++ b/packages/backend/src/remote/activitypub/models/image.ts @@ -68,8 +68,8 @@ export async function createImage( /** * Resolve Image. * - * If the target Image is registered in Firefish, return it, otherwise - * Fetch from remote server, register with Firefish and return it. + * If the target Image is registered in Iceshrimp, return it, otherwise + * Fetch from remote server, register with Iceshrimp and return it. */ export async function resolveImage( actor: CacheableRemoteUser, diff --git a/packages/backend/src/remote/activitypub/models/note.ts b/packages/backend/src/remote/activitypub/models/note.ts index 391f669f3..a0d3bdc65 100644 --- a/packages/backend/src/remote/activitypub/models/note.ts +++ b/packages/backend/src/remote/activitypub/models/note.ts @@ -92,7 +92,7 @@ export function validateNote(object: any, uri: string) { /** * Fetch Notes. * - * If the target Note is registered in Firefish, it will be returned. + * If the target Note is registered in Iceshrimp, it will be returned. */ export async function fetchNote( object: string | IObject, @@ -397,8 +397,8 @@ export async function createNote( /** * Resolve Note. * - * If the target Note is registered in Firefish, return it, otherwise - * Fetch from remote server, register with Firefish and return it. + * If the target Note is registered in Iceshrimp, return it, otherwise + * Fetch from remote server, register with Iceshrimp and return it. */ export async function resolveNote( value: string | IObject, diff --git a/packages/backend/src/remote/activitypub/models/person.ts b/packages/backend/src/remote/activitypub/models/person.ts index 8f17cfae8..927a74a7a 100644 --- a/packages/backend/src/remote/activitypub/models/person.ts +++ b/packages/backend/src/remote/activitypub/models/person.ts @@ -127,7 +127,7 @@ function validateActor(x: IObject, uri: string): IActor { /** * Fetch a Person. * - * If the target Person is registered in Firefish, it will be returned. + * If the target Person is registered in Iceshrimp, it will be returned. */ export async function fetchPerson( uri: string, @@ -378,7 +378,7 @@ export async function createPerson( /** * Update Person data from remote. - * If the target Person is not registered in Firefish, it is ignored. + * If the target Person is not registered in Iceshrimp, it is ignored. * @param uri URI of Person * @param resolver Resolver * @param hint Hint of Person object (If this value is a valid Person, it is used for updating without Remote resolve) @@ -564,8 +564,8 @@ export async function updatePerson( /** * Resolve Person. * - * If the target person is registered in Firefish, it returns it; - * otherwise, it fetches it from the remote server, registers it in Firefish, and returns it. + * If the target person is registered in Iceshrimp, it returns it; + * otherwise, it fetches it from the remote server, registers it in Iceshrimp, and returns it. */ export async function resolvePerson( uri: string, diff --git a/packages/backend/src/server/api/endpoints.ts b/packages/backend/src/server/api/endpoints.ts index 507faf87e..bb34e1a5e 100644 --- a/packages/backend/src/server/api/endpoints.ts +++ b/packages/backend/src/server/api/endpoints.ts @@ -337,7 +337,7 @@ import * as ep___users_stats from "./endpoints/users/stats.js"; import * as ep___fetchRss from "./endpoints/fetch-rss.js"; import * as ep___admin_driveCapOverride from "./endpoints/admin/drive-capacity-override.js"; -//Firefish Move +//Iceshrimp Move import * as ep___i_move from "./endpoints/i/move.js"; import * as ep___i_known_as from "./endpoints/i/known-as.js"; diff --git a/packages/backend/src/server/api/endpoints/latest-version.ts b/packages/backend/src/server/api/endpoints/latest-version.ts index 1cf259c88..338c01a5d 100644 --- a/packages/backend/src/server/api/endpoints/latest-version.ts +++ b/packages/backend/src/server/api/endpoints/latest-version.ts @@ -16,7 +16,7 @@ export const paramDef = { export default define(meta, paramDef, async () => { let tag_name; await fetch( - "https://codeberg.org/api/v1/repos/firefish/firefish/releases?draft=false&pre-release=false&page=1&limit=1", + "https://iceshrimp.dev/api/v1/repos/iceshrimp/iceshrimp/releases?draft=false&pre-release=false&page=1&limit=1", ) .then((response) => response.json()) .then((data) => { diff --git a/packages/backend/src/server/api/endpoints/meta.ts b/packages/backend/src/server/api/endpoints/meta.ts index b1f9eee30..40211ae55 100644 --- a/packages/backend/src/server/api/endpoints/meta.ts +++ b/packages/backend/src/server/api/endpoints/meta.ts @@ -42,7 +42,7 @@ export const meta = { optional: false, nullable: false, format: "url", - example: "https://firefish.example.com", + example: "https://iceshrimp.example.com", }, description: { type: "string", @@ -68,13 +68,13 @@ export const meta = { type: "string", optional: false, nullable: false, - default: "https://codeberg.org/firefish/firefish", + default: "https://iceshrimp.dev/iceshrimp/iceshrimp", }, feedbackUrl: { type: "string", optional: false, nullable: false, - default: "https://codeberg.org/firefish/firefish/issues", + default: "https://iceshrimp.dev/iceshrimp/iceshrimp/issues", }, defaultDarkTheme: { type: "string", diff --git a/packages/backend/src/server/api/endpoints/release.ts b/packages/backend/src/server/api/endpoints/release.ts index a208d87c9..ba03e592a 100644 --- a/packages/backend/src/server/api/endpoints/release.ts +++ b/packages/backend/src/server/api/endpoints/release.ts @@ -18,7 +18,7 @@ export default define(meta, paramDef, async () => { let release; await fetch( - "https://codeberg.org/firefish/firefish/raw/branch/develop/release.json", + "https://iceshrimp.dev/iceshrimp/iceshrimp/raw/branch/dev/release.json", ) .then((response) => response.json()) .then((data) => { diff --git a/packages/backend/src/server/api/mastodon/ApiMastodonCompatibleService.ts b/packages/backend/src/server/api/mastodon/ApiMastodonCompatibleService.ts index 44485ac42..1dc7ca4cc 100644 --- a/packages/backend/src/server/api/mastodon/ApiMastodonCompatibleService.ts +++ b/packages/backend/src/server/api/mastodon/ApiMastodonCompatibleService.ts @@ -103,7 +103,7 @@ export function apiMastodonCompatible(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.dismissInstanceAnnouncement( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data; } catch (e: any) { diff --git a/packages/backend/src/server/api/mastodon/endpoints/account.ts b/packages/backend/src/server/api/mastodon/endpoints/account.ts index 36548cd3b..3ff282a9b 100644 --- a/packages/backend/src/server/api/mastodon/endpoints/account.ts +++ b/packages/backend/src/server/api/mastodon/endpoints/account.ts @@ -114,7 +114,7 @@ export function apiAccountMastodon(router: Router): void { let reqIds = []; for (let i = 0; i < ids.length; i++) { - reqIds.push(convertId(ids[i], IdType.FirefishId)); + reqIds.push(convertId(ids[i], IdType.IceshrimpId)); } const data = await client.getRelationships(reqIds); @@ -135,7 +135,7 @@ export function apiAccountMastodon(router: Router): void { const accessTokens = ctx.headers.authorization; const client = getClient(BASE_URL, accessTokens); try { - const calcId = convertId(ctx.params.id, IdType.FirefishId); + const calcId = convertId(ctx.params.id, IdType.IceshrimpId); const data = await client.getAccount(calcId); ctx.body = convertAccount(data.data); } catch (e: any) { @@ -153,7 +153,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountStatuses( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), convertTimelinesArgsId(argsToBools(limitToInt(ctx.query as any))), ); ctx.body = data.data.map((status) => convertStatus(status)); @@ -173,7 +173,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountFeaturedTags( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data.map((tag) => convertFeaturedTag(tag)); } catch (e: any) { @@ -192,7 +192,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountFollowers( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), convertTimelinesArgsId(limitToInt(ctx.query as any)), ); ctx.body = data.data.map((account) => convertAccount(account)); @@ -212,7 +212,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountFollowing( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), convertTimelinesArgsId(limitToInt(ctx.query as any)), ); ctx.body = data.data.map((account) => convertAccount(account)); @@ -232,7 +232,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountLists( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data.map((list) => convertList(list)); } catch (e: any) { @@ -251,7 +251,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.followAccount( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); let acct = convertRelationship(data.data); acct.following = true; @@ -272,7 +272,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unfollowAccount( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); let acct = convertRelationship(data.data); acct.following = false; @@ -293,7 +293,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.blockAccount( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertRelationship(data.data); } catch (e: any) { @@ -331,7 +331,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.muteAccount( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), (ctx.request as any).body as any, ); ctx.body = convertRelationship(data.data); @@ -351,7 +351,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unmuteAccount( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertRelationship(data.data); } catch (e: any) { @@ -478,7 +478,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.acceptFollowRequest( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertRelationship(data.data); } catch (e: any) { @@ -497,7 +497,7 @@ export function apiAccountMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.rejectFollowRequest( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertRelationship(data.data); } catch (e: any) { diff --git a/packages/backend/src/server/api/mastodon/endpoints/filter.ts b/packages/backend/src/server/api/mastodon/endpoints/filter.ts index e27b7e22a..ff30e90be 100644 --- a/packages/backend/src/server/api/mastodon/endpoints/filter.ts +++ b/packages/backend/src/server/api/mastodon/endpoints/filter.ts @@ -27,7 +27,7 @@ export function apiFilterMastodon(router: Router): void { const body: any = ctx.request.body; try { const data = await client.getFilter( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertFilter(data.data); } catch (e: any) { @@ -59,7 +59,7 @@ export function apiFilterMastodon(router: Router): void { const body: any = ctx.request.body; try { const data = await client.updateFilter( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), body.phrase, body.context, ); @@ -78,7 +78,7 @@ export function apiFilterMastodon(router: Router): void { const body: any = ctx.request.body; try { const data = await client.deleteFilter( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data; } catch (e: any) { diff --git a/packages/backend/src/server/api/mastodon/endpoints/notifications.ts b/packages/backend/src/server/api/mastodon/endpoints/notifications.ts index f0a0bab98..c3ada1bbc 100644 --- a/packages/backend/src/server/api/mastodon/endpoints/notifications.ts +++ b/packages/backend/src/server/api/mastodon/endpoints/notifications.ts @@ -45,7 +45,7 @@ export function apiNotificationsMastodon(router: Router): void { const body: any = ctx.request.body; try { const dataRaw = await client.getNotification( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); const data = convertNotification(dataRaw.data); ctx.body = data; @@ -85,7 +85,7 @@ export function apiNotificationsMastodon(router: Router): void { const body: any = ctx.request.body; try { const data = await client.dismissNotification( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data; } catch (e: any) { diff --git a/packages/backend/src/server/api/mastodon/endpoints/status.ts b/packages/backend/src/server/api/mastodon/endpoints/status.ts index c3e6946e2..61014827d 100644 --- a/packages/backend/src/server/api/mastodon/endpoints/status.ts +++ b/packages/backend/src/server/api/mastodon/endpoints/status.ts @@ -26,9 +26,9 @@ export function apiStatusMastodon(router: Router): void { try { let body: any = ctx.request.body; if (body.in_reply_to_id) - body.in_reply_to_id = convertId(body.in_reply_to_id, IdType.FirefishId); + body.in_reply_to_id = convertId(body.in_reply_to_id, IdType.IceshrimpId); if (body.quote_id) - body.quote_id = convertId(body.quote_id, IdType.FirefishId); + body.quote_id = convertId(body.quote_id, IdType.IceshrimpId); if ( (!body.poll && body["poll[options][]"]) || (!body.media_ids && body["media_ids[]"]) @@ -63,7 +63,7 @@ export function apiStatusMastodon(router: Router): void { if (body.media_ids && !body.media_ids.length) body.media_ids = undefined; if (body.media_ids) { body.media_ids = (body.media_ids as string[]).map((p) => - convertId(p, IdType.FirefishId), + convertId(p, IdType.IceshrimpId), ); } const { sensitive } = body; @@ -102,7 +102,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -117,7 +117,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.deleteStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data; } catch (e: any) { @@ -139,7 +139,7 @@ export function apiStatusMastodon(router: Router): void { const accessTokens = ctx.headers.authorization; const client = getClient(BASE_URL, accessTokens); try { - const id = convertId(ctx.params.id, IdType.FirefishId); + const id = convertId(ctx.params.id, IdType.IceshrimpId); const data = await client.getStatusContext( id, convertTimelinesArgsId(limitToInt(ctx.query as any)), @@ -167,7 +167,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getStatusHistory( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data.map((account) => convertAccount(account)); } catch (e: any) { @@ -185,7 +185,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getStatusRebloggedBy( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data.map((account) => convertAccount(account)); } catch (e: any) { @@ -203,7 +203,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getStatusFavouritedBy( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data.map((account) => convertAccount(account)); } catch (e: any) { @@ -222,7 +222,7 @@ export function apiStatusMastodon(router: Router): void { const react = await getFirstReaction(BASE_URL, accessTokens); try { const a = (await client.createEmojiReaction( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), react, )) as any; //const data = await client.favouriteStatus(ctx.params.id) as any; @@ -244,7 +244,7 @@ export function apiStatusMastodon(router: Router): void { const react = await getFirstReaction(BASE_URL, accessTokens); try { const data = await client.deleteEmojiReaction( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), react, ); ctx.body = convertStatus(data.data); @@ -264,7 +264,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.reblogStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -283,7 +283,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unreblogStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -302,7 +302,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.bookmarkStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -321,7 +321,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unbookmarkStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -340,7 +340,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.pinStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -359,7 +359,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unpinStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertStatus(data.data); } catch (e: any) { @@ -378,7 +378,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.reactStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ctx.params.name, ); ctx.body = convertStatus(data.data); @@ -398,7 +398,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.unreactStatus( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ctx.params.name, ); ctx.body = convertStatus(data.data); @@ -416,7 +416,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getMedia( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertAttachment(data.data); } catch (e: any) { @@ -431,7 +431,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.updateMedia( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ctx.request.body as any, ); ctx.body = convertAttachment(data.data); @@ -447,7 +447,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getPoll( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertPoll(data.data); } catch (e: any) { @@ -464,7 +464,7 @@ export function apiStatusMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.votePoll( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), (ctx.request.body as any).choices, ); ctx.body = convertPoll(data.data); diff --git a/packages/backend/src/server/api/mastodon/endpoints/timeline.ts b/packages/backend/src/server/api/mastodon/endpoints/timeline.ts index 0a4da322d..cf23fc263 100644 --- a/packages/backend/src/server/api/mastodon/endpoints/timeline.ts +++ b/packages/backend/src/server/api/mastodon/endpoints/timeline.ts @@ -46,11 +46,11 @@ export function argsToBools(q: ParsedUrlQuery) { export function convertTimelinesArgsId(q: ParsedUrlQuery) { if (typeof q.min_id === "string") - q.min_id = convertId(q.min_id, IdType.FirefishId); + q.min_id = convertId(q.min_id, IdType.IceshrimpId); if (typeof q.max_id === "string") - q.max_id = convertId(q.max_id, IdType.FirefishId); + q.max_id = convertId(q.max_id, IdType.IceshrimpId); if (typeof q.since_id === "string") - q.since_id = convertId(q.since_id, IdType.FirefishId); + q.since_id = convertId(q.since_id, IdType.IceshrimpId); return q; } @@ -121,7 +121,7 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getListTimeline( - convertId(ctx.params.listId, IdType.FirefishId), + convertId(ctx.params.listId, IdType.IceshrimpId), convertTimelinesArgsId(limitToInt(ctx.query)), ); ctx.body = data.data.map((status) => convertStatus(status)); @@ -173,7 +173,7 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = convertList(data.data); } catch (e: any) { @@ -206,7 +206,7 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.updateList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), (ctx.request.body as any).title, ); ctx.body = convertList(data.data); @@ -226,7 +226,7 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.deleteList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), ); ctx.body = data.data; } catch (e: any) { @@ -245,7 +245,7 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.getAccountsInList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), convertTimelinesArgsId(ctx.query as any), ); ctx.body = data.data.map((account) => convertAccount(account)); @@ -265,9 +265,9 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.addAccountsToList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), (ctx.query.account_ids as string[]).map((id) => - convertId(id, IdType.FirefishId), + convertId(id, IdType.IceshrimpId), ), ); ctx.body = data.data; @@ -287,9 +287,9 @@ export function apiTimelineMastodon(router: Router): void { const client = getClient(BASE_URL, accessTokens); try { const data = await client.deleteAccountsFromList( - convertId(ctx.params.id, IdType.FirefishId), + convertId(ctx.params.id, IdType.IceshrimpId), (ctx.query.account_ids as string[]).map((id) => - convertId(id, IdType.FirefishId), + convertId(id, IdType.IceshrimpId), ), ); ctx.body = data.data; diff --git a/packages/backend/src/server/api/openapi/gen-spec.ts b/packages/backend/src/server/api/openapi/gen-spec.ts index 2ab1689c0..d0585d596 100644 --- a/packages/backend/src/server/api/openapi/gen-spec.ts +++ b/packages/backend/src/server/api/openapi/gen-spec.ts @@ -9,13 +9,13 @@ export function genOpenapiSpec() { info: { version: "v1", - title: "Firefish API", + title: "Iceshrimp API", "x-logo": { url: "/static-assets/api-doc.png" }, }, externalDocs: { description: "Repository", - url: "https://codeberg.org/firefish/firefish", + url: "https://iceshrimp.dev/iceshrimp/iceshrimp", }, servers: [ @@ -106,7 +106,7 @@ export function genOpenapiSpec() { description: desc, externalDocs: { description: "Source code", - url: `https://codeberg.org/firefish/firefish/src/branch/develop/packages/backend/src/server/api/endpoints/${endpoint.name}.ts`, + url: `https://iceshrimp.dev/iceshrimp/iceshrimp/src/branch/dev/packages/backend/src/server/api/endpoints/${endpoint.name}.ts`, }, tags: endpoint.meta.tags || undefined, security, diff --git a/packages/backend/src/server/web/bios.css b/packages/backend/src/server/web/bios.css index d6a1285e9..3d15f6825 100644 --- a/packages/backend/src/server/web/bios.css +++ b/packages/backend/src/server/web/bios.css @@ -45,7 +45,7 @@ main { * { font-family: BIZ UDGothic, Roboto, HelveticaNeue, Arial, sans-serif; } -#firefish_app { +#iceshrimp_app { display: none !important; } body, diff --git a/packages/backend/src/server/web/boot.js b/packages/backend/src/server/web/boot.js index a81ed355a..d06cbf997 100644 --- a/packages/backend/src/server/web/boot.js +++ b/packages/backend/src/server/web/boot.js @@ -185,7 +185,7 @@ font-family: BIZ UDGothic, Roboto, HelveticaNeue, Arial, sans-serif; } - #firefish_app, + #iceshrimp_app, #splash { display: none !important; } diff --git a/packages/backend/src/server/web/cli.css b/packages/backend/src/server/web/cli.css index 740a2aa1a..4b7d3de6c 100644 --- a/packages/backend/src/server/web/cli.css +++ b/packages/backend/src/server/web/cli.css @@ -26,7 +26,7 @@ img { text-align: center; } -#firefish_app { +#iceshrimp_app { display: none !important; } diff --git a/packages/backend/src/server/web/feed.ts b/packages/backend/src/server/web/feed.ts index 50e6bfc32..1cd95c091 100644 --- a/packages/backend/src/server/web/feed.ts +++ b/packages/backend/src/server/web/feed.ts @@ -43,7 +43,7 @@ export default async function ( id: author.link, title: `${author.name} (@${user.username}@${config.host})`, updated: notes[0].createdAt, - generator: "Firefish", + generator: "Iceshrimp", description: `${user.notesCount} Notes, ${ profile.ffVisibility === "public" ? user.followingCount : "?" } Following, ${ diff --git a/packages/backend/src/server/web/manifest.json b/packages/backend/src/server/web/manifest.json index 7f70ac2c9..2aa7ec310 100644 --- a/packages/backend/src/server/web/manifest.json +++ b/packages/backend/src/server/web/manifest.json @@ -1,6 +1,6 @@ { - "short_name": "Firefish", - "name": "Firefish", + "short_name": "Iceshrimp", + "name": "Iceshrimp", "description": "An open source, decentralized social media platform that's free forever!", "start_url": "/", "display": "standalone", diff --git a/packages/backend/src/server/web/manifest.ts b/packages/backend/src/server/web/manifest.ts index 6ca9791ba..e1bee8aae 100644 --- a/packages/backend/src/server/web/manifest.ts +++ b/packages/backend/src/server/web/manifest.ts @@ -9,8 +9,8 @@ export const manifestHandler = async (ctx: Koa.Context) => { const instance = await fetchMeta(true); - res.short_name = instance.name || "Firefish"; - res.name = instance.name || "Firefish"; + res.short_name = instance.name || "Iceshrimp"; + res.name = instance.name || "Iceshrimp"; if (instance.themeColor) res.theme_color = instance.themeColor; ctx.set("Cache-Control", "max-age=300"); diff --git a/packages/backend/src/services/logger.ts b/packages/backend/src/services/logger.ts index 146dae2ea..5a77246e2 100644 --- a/packages/backend/src/services/logger.ts +++ b/packages/backend/src/services/logger.ts @@ -29,7 +29,7 @@ export default class Logger { if (config.syslog) { this.syslogClient = new SyslogPro.RFC5424({ - applacationName: "Firefish", + applacationName: "Iceshrimp", timestamp: true, encludeStructuredData: true, color: true, diff --git a/packages/backend/test/mfm.ts b/packages/backend/test/mfm.ts index 926bdd259..d4fe201e4 100644 --- a/packages/backend/test/mfm.ts +++ b/packages/backend/test/mfm.ts @@ -55,33 +55,33 @@ describe("fromHtml", () => { it("link with different text", () => { assert.deepStrictEqual( - fromHtml('

a c d

'), - "a [c](https://joinfirefish.org/b) d", + fromHtml('

a c d

'), + "a [c](https://iceshrimp.dev/b) d", ); }); it("link with different text, but not encoded", () => { assert.deepStrictEqual( - fromHtml('

a c d

'), - "a [c]() d", + fromHtml('

a c d

'), + "a [c]() d", ); }); it("link with same text", () => { assert.deepStrictEqual( fromHtml( - '

a https://joinfirefish.org/b d

', + '

a https://joiniceshrimp.org/b d

', ), - "a https://joinfirefish.org/b d", + "a https://joiniceshrimp.org/b d", ); }); it("link with same text, but not encoded", () => { assert.deepStrictEqual( fromHtml( - '

a https://joinfirefish.org/รค d

', + '

a https://joiniceshrimp.org/รค d

', ), - "a d", + "a d", ); }); @@ -98,8 +98,8 @@ describe("fromHtml", () => { it("link without text", () => { assert.deepStrictEqual( - fromHtml('

a d

'), - "a https://joinfirefish.org/b d", + fromHtml('

a d

'), + "a https://joiniceshrimp.org/b d", ); }); @@ -110,15 +110,15 @@ describe("fromHtml", () => { it("mention", () => { assert.deepStrictEqual( fromHtml( - '

a @user d

', + '

a @user d

', ), - "a @user@joinfirefish.org d", + "a @user@joiniceshrimp.org d", ); }); it("hashtag", () => { assert.deepStrictEqual( - fromHtml('

a #a d

', [ + fromHtml('

a #a d

', [ "#a", ]), "a #a d", diff --git a/packages/client/src/components/MkInstanceCardMini.vue b/packages/client/src/components/MkInstanceCardMini.vue index 72db84137..ff242f5a6 100644 --- a/packages/client/src/components/MkInstanceCardMini.vue +++ b/packages/client/src/components/MkInstanceCardMini.vue @@ -24,13 +24,13 @@