diff --git a/site/.prettierrc b/site/.prettierrc index ad8cf6c6..59bb36fc 100644 --- a/site/.prettierrc +++ b/site/.prettierrc @@ -1,5 +1,13 @@ { "semi": false, "singleQuote": true, - "arrowParens": "always" + "arrowParens": "always", + "overrides": [ + { + "files": "*.md", + "options": { + "singleQuote": false + } + } + ] } diff --git a/site/src/docs/backup/url-migration/index.md b/site/src/docs/backup/url-migration/index.md index 3c3b02af..a5773943 100644 --- a/site/src/docs/backup/url-migration/index.md +++ b/site/src/docs/backup/url-migration/index.md @@ -12,21 +12,22 @@ First you have to create a `rules` file in remark's `/var` folder. Format is simply `old_url new_url` like following: - ``` - https://example.org/old-url-1/ https://example.org/new-url-1/ - https://example.org/old-url-2/ https://example.org/new-url-2/ - ``` +``` +https://example.org/old-url-1/ https://example.org/new-url-1/ +https://example.org/old-url-2/ https://example.org/new-url-2/ +``` ### Applying the remap After rules file is ready, run the following command: - ```shell - remark42 remap --admin-passwd -f var/rules - ``` +```shell +remark42 remap --admin-passwd -f var/rules +``` If running in a docker container, the command becomes: - ```shell - docker ps # to find the container name - docker exec -it remark42 remap --admin-passwd -f var/rules - ``` + +```shell +docker ps # to find the container name +docker exec -it remark42 remap --admin-passwd -f var/rules +``` diff --git a/site/src/docs/configuration/email/index.md b/site/src/docs/configuration/email/index.md index e399cd31..64cd5fe4 100644 --- a/site/src/docs/configuration/email/index.md +++ b/site/src/docs/configuration/email/index.md @@ -71,14 +71,14 @@ Here is `docker-compose.yml` configuration part spinning up a container for ```yaml mailgun: image: stevenolen/mailgun-smtp-server - container_name: 'mail' - hostname: 'mail' + container_name: "mail" + hostname: "mail" logging: driver: json-file options: - max-size: '10m' - max-file: '5' + max-size: "10m" + max-file: "5" environment: - MG_KEY=key-123456789 @@ -124,14 +124,14 @@ Here is `docker-compose.yml` configuration part spinning up a container for ```yaml sendgrid: image: fgribreau/smtp-to-sendgrid-gateway - container_name: 'mail' - hostname: 'mail' + container_name: "mail" + hostname: "mail" logging: driver: json-file options: - max-size: '10m' - max-file: '5' + max-size: "10m" + max-file: "5" environment: - SENDGRID_API=key-123456789 diff --git a/site/src/docs/configuration/kubernetes/index.md b/site/src/docs/configuration/kubernetes/index.md index 70cca757..f0f6b7f2 100644 --- a/site/src/docs/configuration/kubernetes/index.md +++ b/site/src/docs/configuration/kubernetes/index.md @@ -35,67 +35,67 @@ spec: app: remark42 spec: containers: - - name: remark42 - image: umputun/remark42:v1.8.1 - ports: - # http: - - containerPort: 8080 - env: - - name: REMARK_URL - value: "https://comments.mysite.com/" - - name: "SITE" - value: "mysite.com" - - name: SECRET - valueFrom: - secretKeyRef: - name: remark42 - key: SECRET - - name: STORE_BOLT_PATH - value: "/srv/var/db" - - name: BACKUP_PATH - value: "/srv/var/backup" - - name: AUTH_GOOGLE_CID - valueFrom: - secretKeyRef: - name: remark42 - key: AUTH_GOOGLE_CID - - name: AUTH_GOOGLE_CSEC - valueFrom: - secretKeyRef: - name: remark42 - key: AUTH_GOOGLE_CSEC - - name: AUTH_GITHUB_CID - valueFrom: - secretKeyRef: - name: remark42 - key: AUTH_GITHUB_CID - - name: AUTH_GITHUB_CSEC - valueFrom: - secretKeyRef: - name: remark42 - key: AUTH_GITHUB_CSEC - - name: ADMIN_SHARED_ID - value: "google_b182b5daa0004104b348d9bde762b1880ed9d98d" - - name: TIME_ZONE - value: "Europe/Dublin" - volumeMounts: - - name: srvvar - mountPath: /srv/var - securityContext: - readOnlyRootFilesystem: false - resources: - requests: - cpu: "100m" - memory: "25Mi" - limits: - cpu: "1" - memory: "1Gi" + - name: remark42 + image: umputun/remark42:v1.8.1 + ports: + # http: + - containerPort: 8080 + env: + - name: REMARK_URL + value: "https://comments.mysite.com/" + - name: "SITE" + value: "mysite.com" + - name: SECRET + valueFrom: + secretKeyRef: + name: remark42 + key: SECRET + - name: STORE_BOLT_PATH + value: "/srv/var/db" + - name: BACKUP_PATH + value: "/srv/var/backup" + - name: AUTH_GOOGLE_CID + valueFrom: + secretKeyRef: + name: remark42 + key: AUTH_GOOGLE_CID + - name: AUTH_GOOGLE_CSEC + valueFrom: + secretKeyRef: + name: remark42 + key: AUTH_GOOGLE_CSEC + - name: AUTH_GITHUB_CID + valueFrom: + secretKeyRef: + name: remark42 + key: AUTH_GITHUB_CID + - name: AUTH_GITHUB_CSEC + valueFrom: + secretKeyRef: + name: remark42 + key: AUTH_GITHUB_CSEC + - name: ADMIN_SHARED_ID + value: "google_b182b5daa0004104b348d9bde762b1880ed9d98d" + - name: TIME_ZONE + value: "Europe/Dublin" + volumeMounts: + - name: srvvar + mountPath: /srv/var + securityContext: + readOnlyRootFilesystem: false + resources: + requests: + cpu: "100m" + memory: "25Mi" + limits: + cpu: "1" + memory: "1Gi" securityContext: # Has its own root privilege drop. Can't do runAsUser / runAsGroup. volumes: - - name: srvvar - persistentVolumeClaim: - claimName: remark42 + - name: srvvar + persistentVolumeClaim: + claimName: remark42 --- apiVersion: v1 kind: PersistentVolumeClaim @@ -104,7 +104,7 @@ metadata: namespace: remark42 spec: accessModes: - - ReadWriteOnce + - ReadWriteOnce resources: requests: storage: 10Gi @@ -135,18 +135,18 @@ metadata: cert-manager.io/cluster-issuer: "letsencrypt-prod" spec: tls: - - hosts: - - comments.mysite.com - secretName: comments-tls + - hosts: + - comments.mysite.com + secretName: comments-tls rules: - - host: "comments.mysite.com" - http: - paths: - - path: / - pathType: Prefix - backend: - serviceName: remark42-web - servicePort: 8080 + - host: "comments.mysite.com" + http: + paths: + - path: / + pathType: Prefix + backend: + serviceName: remark42-web + servicePort: 8080 ``` Change `storageClassName` if you run on top of different cloud / bare metal. diff --git a/site/src/docs/configuration/notifications/index.md b/site/src/docs/configuration/notifications/index.md index 6ab171fc..d2c4519c 100644 --- a/site/src/docs/configuration/notifications/index.md +++ b/site/src/docs/configuration/notifications/index.md @@ -16,7 +16,7 @@ In order to integrate notifications from remark42 with the [slack](https://slack 2. Click the OAuth & Permissions tab in the left sidebar. 3. Below Bot Token Scopes, select the `chat:write`, `chat:write.public` and `channels:read` scopes. Then click Add an OAuth Scope. 4. Scroll to the top of the page, and click on Install to workspace. -5. You should see the "_View basic information about public channels in your workspace_", "_Send Message as ..._" and "_Send messages to channels ... isn't a member of_" as the permission, then click allow. +5. You should see the "_View basic information about public channels in your workspace_", "_Send Message as ..._" and "_Send messages to channels ... isn't a member of_" as the permission, then click allow. 6. You can then see you token, in the form of `xoxb-...-...-...` ### Remark42 configuration @@ -38,15 +38,16 @@ By default, the notification are sent to the `general` channel on slack. If you If all goes fine, you should be able to see the following message on your Slack notification channel: > New comment from _author_ -> _original author_ ->> [Demo | Remark42](http://127.0.0.1:8080/web/#remark42__comment-11288987987) ->> This is the comment written by _author_ - +> +> > [Demo | Remark42](http://127.0.0.1:8080/web/#remark42__comment-11288987987) +> > This is the comment written by _author_ ## Telegram ### Telegram notifications for administrators In order to integrate notifications about any comment on your sites with remark42 with [telegram](https://telegram.org) + 1. Set `NOTIFY_ADMINS=telegram` 1. Make [a channel](https://telegram.org/faq_channels) and add it to remark42 configuration as `NOTIFY_TELEGRAM_CHAN` 1. Get a token according to the instruction below and add it to the configuration as well diff --git a/site/src/docs/configuration/reproxy/index.md b/site/src/docs/configuration/reproxy/index.md index 46d66f75..f5cdeec0 100644 --- a/site/src/docs/configuration/reproxy/index.md +++ b/site/src/docs/configuration/reproxy/index.md @@ -82,7 +82,7 @@ services: labels: reproxy.server: remark42.example.com reproxy.port: "8080" - reproxy.route: '^/(.*)' - reproxy.dest: '/$$1' - reproxy.ping: '/ping' + reproxy.route: "^/(.*)" + reproxy.dest: "/$$1" + reproxy.ping: "/ping" ``` diff --git a/site/src/docs/configuration/subdomain/index.md b/site/src/docs/configuration/subdomain/index.md index 72445563..a6a82b18 100644 --- a/site/src/docs/configuration/subdomain/index.md +++ b/site/src/docs/configuration/subdomain/index.md @@ -14,9 +14,9 @@ All README examples show configurations with remark42 on its own subdomain, i.e. - The backend `REMARK_URL` parameter will be `https://example.com/remark42` - And you also need to slightly modify the callback URL for the social media login API's: - - Facebook Valid OAuth Redirect URIs: `https://example.com/remark42/auth/facebook/callback` - - Google Authorized redirect URIs: `https://example.com/remark42/auth/google/callback` - - GitHub Authorised callback URL: `https://example.com/remark42/auth/github/callback` + - Facebook Valid OAuth Redirect URIs: `https://example.com/remark42/auth/facebook/callback` + - Google Authorized redirect URIs: `https://example.com/remark42/auth/google/callback` + - GitHub Authorised callback URL: `https://example.com/remark42/auth/github/callback` ### docker-compose configuration @@ -25,7 +25,7 @@ Both Nginx and Caddy configuration below relies on remark42 available on hostnam Example `docker-compose.yaml`: ```yaml -version: '2' +version: "2" services: remark42: image: umputun/remark42:latest @@ -40,8 +40,8 @@ services: - ./data:/srv/var logging: options: - max-size: '10m' - max-file: '1' + max-size: "10m" + max-file: "1" ``` ### Nginx configuration diff --git a/site/src/docs/getting-started/installation/index.md b/site/src/docs/getting-started/installation/index.md index 9a34c008..42e97244 100644 --- a/site/src/docs/getting-started/installation/index.md +++ b/site/src/docs/getting-started/installation/index.md @@ -28,10 +28,10 @@ Add config for Remark on a page of your site: ```html ``` @@ -42,10 +42,10 @@ For example: ```html ```