Merge branch 'master' of github.com:Ocelot-Social-Community/Ocelot-Social

This commit is contained in:
Markus 2024-01-31 12:13:37 +01:00
commit a6cdf934e5
76 changed files with 19559 additions and 2336 deletions

View File

@ -12,5 +12,20 @@ webapp: &webapp
- 'webapp/**/*' - 'webapp/**/*'
- 'package.json' - 'package.json'
markdown-files: &markdown-files docs-check: &docs-check
- '.github/workflows/check-documentation.yml'
markdown: &markdown
- *docs-check
- '**/*.md' - '**/*.md'
- '.github/workflows/mlc_config.json'
vuepress: &vuepress
- *docs-check
- '.github/workflows/deploy-documentation.yml'
- '.vuepress/**/*'
- 'package.json'
documentation: &documentation
- *vuepress
- *markdown

View File

@ -7,13 +7,14 @@ jobs:
name: Detect File Changes - Markdown files name: Detect File Changes - Markdown files
runs-on: ubuntu-latest runs-on: ubuntu-latest
outputs: outputs:
markdown-files: ${{ steps.changes.outputs.markdown-files }} markdown: ${{ steps.changes.outputs.markdown }}
documentation: ${{ steps.changes.outputs.documentation }}
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@master uses: actions/checkout@master
- name: Check for markdown file changes - name: Check for markdown file changes
uses: dorny/paths-filter@v2.11.1 uses: dorny/paths-filter@v3.0.0
id: changes id: changes
with: with:
token: ${{ github.token }} token: ${{ github.token }}
@ -22,19 +23,43 @@ jobs:
check-markdown-links: check-markdown-links:
name: Check Markdown links name: Check Markdown links
if: needs.files-changed.outputs.markdown-files == 'true'
needs: files-changed needs: files-changed
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: needs.files-changed.outputs.markdown == 'true'
steps: steps:
- name: Checkout code - name: Checkout code
uses: actions/checkout@master uses: actions/checkout@master
- name: Check Markdown Links
uses: gaurav-nelson/github-action-markdown-link-check@master - name: Remove old documentation files
with: run: rm -rf ./deployment/src/old/ ./CHANGELOG.md # workaround until https://github.com/gaurav-nelson/github-action-markdown-link-check/pull/183 has been done
use-quiet-mode: 'yes'
use-verbose-mode: 'no' - name: Check Markdown Links
# at any .md file change take the chance to check the links in all .md files uses: gaurav-nelson/github-action-markdown-link-check@master
check-modified-files-only: 'no' with:
config-file: '.github/workflows/mlc_config.json' use-quiet-mode: 'yes'
base-branch: 'master' use-verbose-mode: 'no'
folder-path: '.' # at any .md file change take the chance to check the links in all .md files
check-modified-files-only: 'no'
config-file: '.github/workflows/mlc_config.json'
base-branch: 'master'
folder-path: '.'
test-vuepress-build:
name: Test Vuepress build
needs: files-changed
runs-on: ubuntu-latest
if: needs.files-changed.outputs.documentation == 'true'
steps:
- name: Checkout code
uses: actions/checkout@master
- name: Setup Node 20
uses: actions/setup-node@v4
with:
node-version: '20'
- name: npm-install
run: npm install
- name: npm-docs:build
run: npm run docs:build

View File

@ -0,0 +1,48 @@
name: ocelot.social deploy documentation
on:
push:
branches:
- master
jobs:
files-changed:
name: Detect File Changes - Markdown and Vuepress files
runs-on: ubuntu-latest
outputs:
documentation: ${{ steps.changes.outputs.documentation }}
steps:
- name: Checkout code
uses: actions/checkout@master
- name: Check for file changes
uses: dorny/paths-filter@master
id: changes
with:
token: ${{ github.token }}
filters: .github/file-filters.yml
list-files: shell
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: Setup Node 20
uses: actions/setup-node@v4
with:
node-version: 20
- name: Build Vuepress Pages
run: npm install && npm run docs:build
- name: Deploy Vuepress to Github Pages
uses: crazy-max/ghaction-github-pages@v4
with:
target_branch: gh-pages
build_dir: .vuepress/dist
author: Wolfgang Huß <vorstand@busfaktor.org>
fqdn: docs.ocelot.social
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@ -3,10 +3,10 @@
"retryOn429": true, "retryOn429": true,
"retryCount": 2, "retryCount": 2,
"fallbackRetryDelay": "30s", "fallbackRetryDelay": "30s",
"aliveStatusCodes": [200, 206], "aliveStatusCodes": [200, 206, 303, 403],
"ignorePatterns": [ "ignorePatterns": [
{ {
"pattern": "^(https:\/\/github.com\/Ocelot-Social-Community\/Ocelot-Social\/pull\/|http:\/\/localhost)" "pattern": "^(https:\/\/github.com\/Ocelot-Social-Community\/Ocelot-Social\/(pull|deployment\/src\/old)\/|http:\/\/localhost)"
} }
] ]
} }

View File

@ -34,7 +34,7 @@ jobs:
- name: Neo4J | Save docker image - name: Neo4J | Save docker image
run: docker save "ocelotsocialnetwork/neo4j-community" > /tmp/neo4j.tar run: docker save "ocelotsocialnetwork/neo4j-community" > /tmp/neo4j.tar
- name: Upload Artifact - name: Upload Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v4
with: with:
name: docker-neo4j-community name: docker-neo4j-community
path: /tmp/neo4j.tar path: /tmp/neo4j.tar
@ -83,7 +83,7 @@ jobs:
- name: Backend | Save docker image - name: Backend | Save docker image
run: docker save "ocelotsocialnetwork/backend" > /tmp/backend.tar run: docker save "ocelotsocialnetwork/backend" > /tmp/backend.tar
- name: Upload Artifact - name: Upload Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v4
with: with:
name: docker-backend-production name: docker-backend-production
path: /tmp/backend.tar path: /tmp/backend.tar
@ -132,7 +132,7 @@ jobs:
- name: Webapp | Save docker image - name: Webapp | Save docker image
run: docker save "ocelotsocialnetwork/webapp" > /tmp/webapp.tar run: docker save "ocelotsocialnetwork/webapp" > /tmp/webapp.tar
- name: Upload Artifact - name: Upload Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v4
with: with:
name: docker-webapp-production name: docker-webapp-production
path: /tmp/webapp.tar path: /tmp/webapp.tar
@ -184,7 +184,7 @@ jobs:
- name: Maintenance | Save docker image - name: Maintenance | Save docker image
run: docker save "ocelotsocialnetwork/maintenance" > /tmp/maintenance.tar run: docker save "ocelotsocialnetwork/maintenance" > /tmp/maintenance.tar
- name: Upload Artifact - name: Upload Artifact
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v4
with: with:
name: docker-maintenance-production name: docker-maintenance-production
path: /tmp/maintenance.tar path: /tmp/maintenance.tar
@ -201,25 +201,25 @@ jobs:
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }} DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
steps: steps:
- name: Download Docker Image (Neo4J) - name: Download Docker Image (Neo4J)
uses: actions/download-artifact@v3 uses: actions/download-artifact@v4
with: with:
name: docker-neo4j-community name: docker-neo4j-community
path: /tmp path: /tmp
- run: docker load < /tmp/neo4j.tar - run: docker load < /tmp/neo4j.tar
- name: Download Docker Image (Backend) - name: Download Docker Image (Backend)
uses: actions/download-artifact@v3 uses: actions/download-artifact@v4
with: with:
name: docker-backend-production name: docker-backend-production
path: /tmp path: /tmp
- run: docker load < /tmp/backend.tar - run: docker load < /tmp/backend.tar
- name: Download Docker Image (WebApp) - name: Download Docker Image (WebApp)
uses: actions/download-artifact@v3 uses: actions/download-artifact@v4
with: with:
name: docker-webapp-production name: docker-webapp-production
path: /tmp path: /tmp
- run: docker load < /tmp/webapp.tar - run: docker load < /tmp/webapp.tar
- name: Download Docker Image (Maintenance) - name: Download Docker Image (Maintenance)
uses: actions/download-artifact@v3 uses: actions/download-artifact@v4
with: with:
name: docker-maintenance-production name: docker-maintenance-production
path: /tmp path: /tmp
@ -253,7 +253,7 @@ jobs:
echo "BUILD_COMMIT=${GITHUB_SHA}" >> $GITHUB_ENV echo "BUILD_COMMIT=${GITHUB_SHA}" >> $GITHUB_ENV
- run: echo "BUILD_VERSION=${VERSION}-${GITHUB_RUN_NUMBER}" >> $GITHUB_ENV - run: echo "BUILD_VERSION=${VERSION}-${GITHUB_RUN_NUMBER}" >> $GITHUB_ENV
- name: package-version-to-git-tag + build number - name: package-version-to-git-tag + build number
uses: pkgdeps/git-tag-action@v2 uses: pkgdeps/git-tag-action@v3
with: with:
github_token: ${{ secrets.GITHUB_TOKEN }} github_token: ${{ secrets.GITHUB_TOKEN }}
github_repo: ${{ github.repository }} github_repo: ${{ github.repository }}

View File

@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Check for backend file changes - name: Check for backend file changes
uses: dorny/paths-filter@v2.11.1 uses: dorny/paths-filter@v3.0.0
id: changes id: changes
with: with:
token: ${{ github.token }} token: ${{ github.token }}
@ -37,7 +37,7 @@ jobs:
- name: Cache docker images - name: Cache docker images
id: cache-neo4j id: cache-neo4j
uses: actions/cache/save@v3.3.2 uses: actions/cache/save@v4.0.0
with: with:
path: /tmp/neo4j.tar path: /tmp/neo4j.tar
key: ${{ github.run_id }}-backend-neo4j-cache key: ${{ github.run_id }}-backend-neo4j-cache
@ -58,7 +58,7 @@ jobs:
- name: Cache docker images - name: Cache docker images
id: cache-backend id: cache-backend
uses: actions/cache/save@v3.3.2 uses: actions/cache/save@v4.0.0
with: with:
path: /tmp/backend.tar path: /tmp/backend.tar
key: ${{ github.run_id }}-backend-cache key: ${{ github.run_id }}-backend-cache
@ -87,14 +87,14 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Restore Neo4J cache - name: Restore Neo4J cache
uses: actions/cache/restore@v3.3.2 uses: actions/cache/restore@v4.0.0
with: with:
path: /tmp/neo4j.tar path: /tmp/neo4j.tar
key: ${{ github.run_id }}-backend-neo4j-cache key: ${{ github.run_id }}-backend-neo4j-cache
fail-on-cache-miss: true fail-on-cache-miss: true
- name: Restore Backend cache - name: Restore Backend cache
uses: actions/cache/restore@v3.3.2 uses: actions/cache/restore@v4.0.0
with: with:
path: /tmp/backend.tar path: /tmp/backend.tar
key: ${{ github.run_id }}-backend-cache key: ${{ github.run_id }}-backend-cache

View File

@ -36,7 +36,7 @@ jobs:
- name: Cache docker images - name: Cache docker images
id: cache id: cache
uses: actions/cache/save@v3.3.2 uses: actions/cache/save@v4.0.0
with: with:
path: | path: |
/opt/cucumber-json-formatter /opt/cucumber-json-formatter
@ -58,7 +58,7 @@ jobs:
job: [1, 2, 3, 4, 5, 6, 7, 8] job: [1, 2, 3, 4, 5, 6, 7, 8]
steps: steps:
- name: Restore cache - name: Restore cache
uses: actions/cache/restore@v3.3.2 uses: actions/cache/restore@v4.0.0
id: cache id: cache
with: with:
path: | path: |
@ -92,7 +92,7 @@ jobs:
- name: Full stack tests | if tests failed, upload report - name: Full stack tests | if tests failed, upload report
id: e2e-report id: e2e-report
if: ${{ failure() && steps.e2e-tests.conclusion == 'failure' }} if: ${{ failure() && steps.e2e-tests.conclusion == 'failure' }}
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v4
with: with:
name: ocelot-e2e-test-report-pr${{ needs.docker_preparation.outputs.pr-number }} name: ocelot-e2e-test-report-pr${{ needs.docker_preparation.outputs.pr-number }}
path: /home/runner/work/Ocelot-Social/Ocelot-Social/cypress/reports/cucumber_html_report path: /home/runner/work/Ocelot-Social/Ocelot-Social/cypress/reports/cucumber_html_report

View File

@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Check for frontend file changes - name: Check for frontend file changes
uses: dorny/paths-filter@v2.11.1 uses: dorny/paths-filter@v3.0.0
id: changes id: changes
with: with:
token: ${{ github.token }} token: ${{ github.token }}
@ -50,7 +50,7 @@ jobs:
docker save "ocelotsocialnetwork/webapp:test" > /tmp/webapp.tar docker save "ocelotsocialnetwork/webapp:test" > /tmp/webapp.tar
- name: Cache docker image - name: Cache docker image
uses: actions/cache/save@v3.3.2 uses: actions/cache/save@v4.0.0
with: with:
path: /tmp/webapp.tar path: /tmp/webapp.tar
key: ${{ github.run_id }}-webapp-cache key: ${{ github.run_id }}-webapp-cache
@ -79,7 +79,7 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Restore webapp cache - name: Restore webapp cache
uses: actions/cache/restore@v3.3.2 uses: actions/cache/restore@v4.0.0
with: with:
path: /tmp/webapp.tar path: /tmp/webapp.tar
key: ${{ github.run_id }}-webapp-cache key: ${{ github.run_id }}-webapp-cache

8
.gitignore vendored
View File

@ -8,14 +8,20 @@ yarn-error.log*
.yarn-integrity .yarn-integrity
.eslintcache .eslintcache
kubeconfig.yaml kubeconfig.yaml
backup-cron-job.log
node_modules/ node_modules/
cypress/videos cypress/videos
cypress/screenshots/ cypress/screenshots/
cypress.env.json cypress.env.json
.vuepress/.cache/
.vuepress/.temp/
.vuepress/dist/
!.gitkeep !.gitkeep
**/coverage **/coverage
release/ release/
*~ *~

12
.vuepress/config.js Normal file
View File

@ -0,0 +1,12 @@
import { defineUserConfig } from 'vuepress'
import { viteBundler } from '@vuepress/bundler-vite'
import meta from './config/meta'
import theme from './config/theme'
export default defineUserConfig({
pagePatterns: ['**/*.md', '!.vuepress', '!node_modules', '!backend/node_modules', '!webapp/node_modules', '!deployment/src/old'],
bundler: viteBundler(),
...meta,
theme,
})

8
.vuepress/config/meta.js Normal file
View File

@ -0,0 +1,8 @@
export default {
base: '/',
title: 'Ocelot.Social Documentation',
description: 'Ocelot.Social Documentation',
head: [
['meta', {name: 'viewport', content: 'width=device-width,initial-scale=1'}],
],
}

96
.vuepress/config/theme.js Normal file
View File

@ -0,0 +1,96 @@
import path from 'path'
import fs from 'fs'
import { hopeTheme } from 'vuepress-theme-hope'
export default hopeTheme({
favicon: 'favicon.ico',
logo: '/logo.svg',
docsRepo: 'https://github.com/Ocelot-Social-Community/Ocelot-Social',
docsBranch: 'master',
docsDir: '.',
editLink: true,
lastUpdated: false,
contributors: false,
print: false,
pure: true,
displayFooter: true,
footer: 'CC BY busFaktor() e.V. & Authors',
sidebar: generateSidebar('../../SUMMARY.md'),
navbar: [
{ text: 'Home', link: '/' },
{
text: 'Github',
link: 'https://github.com/Ocelot-Social-Community/Ocelot-Social'
},
],
plugins: {
mdEnhance: {
tabs: true,
imgSize: true
},
searchPro: {
indexContent: true,
autoSuggestions: true,
customFields: [
{
getter: (page) => page.frontmatter.category,
formatter: "Category: $content",
},
{
getter: (page) => page.frontmatter.tag,
formatter: "Tag: $content",
},
],
}
}
})
function generateSidebar(summaryFileName) {
const summaryFile = path.resolve(__dirname, summaryFileName)
try {
return getSummaryData(summaryFile)
} catch (err) {
console.error(`Error generating sidebar from file ${summaryFileName}:`, err)
process.exit(1)
}
}
function getSummaryData(file) {
const lines = fs.readFileSync(file, 'utf8').split('\n')
const sidebarStructure = []
let currentParent = null
lines.forEach((line, i) => {
const level = line.search(/\S|$/) / 2
const match = line.match(/^\s*\*\s*\[([^\]]+)\]\(([^)]+)\)/)
if (match) {
const newEntry = { text: match[1], link: `/${match[2]}`, children: [] }
if (level === 0) {
sidebarStructure.push(newEntry)
currentParent = sidebarStructure[sidebarStructure.length - 1]
} else {
let parent = currentParent
for (let i = 1; i < level; i++) {
parent = parent.children[parent.children.length - 1]
}
parent.children.push(newEntry)
}
}
})
sidebarStructure.forEach(removeEmptyArrays)
return sidebarStructure
}
function removeEmptyArrays(item) {
if (item.children && item.children.length === 0) {
delete item.children;
} else if (item.children) {
item.children.forEach(removeEmptyArrays);
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

65
.vuepress/public/logo.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 28 KiB

View File

@ -4,7 +4,7 @@ Thank you so much for thinking of contributing to the [ocelot.social](https://oc
## Getting Set Up ## Getting Set Up
Instructions for how to install all the necessary software and some code guidelines can be found in our main [Readme](/README.md) or in our [documentation](/SUMMARY.md). Instructions for how to install all the necessary software and some code guidelines can be found in our main [Readme](./README.md) or in our [documentation](./SUMMARY.md).
To get you started we recommend that you join forces with a regular contributor. Please join [our Discord instance](https://discord.gg/AJSX9DCSUA) to chat with developers or just get in touch directly on an issue on either [Github](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues) or [Zenhub](https://app.zenhub.com/workspaces/ocelotsocial-5fb21ff922cb410015dd6535/board?filterLogic=any&repos=301151089): To get you started we recommend that you join forces with a regular contributor. Please join [our Discord instance](https://discord.gg/AJSX9DCSUA) to chat with developers or just get in touch directly on an issue on either [Github](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues) or [Zenhub](https://app.zenhub.com/workspaces/ocelotsocial-5fb21ff922cb410015dd6535/board?filterLogic=any&repos=301151089):
@ -36,7 +36,7 @@ Every pull request needs to:
## Contribution Flow For Open Source Contributors ## Contribution Flow For Open Source Contributors
See [contributing in main README.md](/README.md#contributing) See [contributing in main README.md](./README.md#contributing)
## The Team ## The Team
@ -48,6 +48,9 @@ You can talk to our core team on [Discord](https://discord.gg/AJSX9DCSUA). And o
* Moriz (@Mogge) * Moriz (@Mogge)
* Wolle (@Tirokk) * Wolle (@Tirokk)
* Alex (@ogerly) * Alex (@ogerly)
* Hannes (@elweyn5803)
* Mathias (@mahula)
* Markus (@maeckes#1133)
<!-- * Robert (@roschaefer) <!-- * Robert (@roschaefer)
* Matt (@mattwr18) * Matt (@mattwr18)

View File

@ -2,15 +2,16 @@
[![Build Status Test](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions/workflows/test.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions) [![Build Status Test](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions/workflows/test.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions)
[![Build Status Publish](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions/workflows/publish.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions) [![Build Status Publish](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions/workflows/publish.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/actions)
[![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/LICENSE.md) [![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/LICENSE.md)
[![Discord Channel](https://img.shields.io/discord/489522408076738561.svg)](https://discord.gg/AJSX9DCSUA) [![Discord Channel](https://img.shields.io/discord/489522408076738561.svg)](https://discord.gg/AJSX9DCSUA)
[![Open Source Helpers](https://www.codetriage.com/ocelot-social-community/ocelot-social/badges/users.svg)](https://www.codetriage.com/ocelot-social-community/ocelot-social) [![Open Source Helpers](https://www.codetriage.com/ocelot-social-community/ocelot-social/badges/users.svg)](https://www.codetriage.com/ocelot-social-community/ocelot-social)
[Ocelot.social](https://ocelot.social) is free and open source software program code to run social networks. Its development is supported by a community of programmers and interested network operators. [Ocelot.social](https://ocelot.social) is free and open source software program code to run social networks. Its development is supported by a community of programmers and interested network operators.
<!-- markdownlint-disable MD033 --> <!-- markdownlint-disable MD033 -->
<p align="center"> <!-- <p align="center"> -->
<a href="https://ocelot.social" target="_blank"><img src="webapp/static/img/custom/logo-squared.svg" alt="ocelot.social" width="40%" height="40%"></a> <p style="text-align: center;">
<a href="https://ocelot.social" target="_blank"><img src="https://raw.githubusercontent.com/Ocelot-Social-Community/Ocelot-Social/master/webapp/static/img/custom/logo-squared.svg" alt="ocelot.social" width="40%" height="40%"></a>
</p> </p>
<!-- markdownlint-enable MD033 --> <!-- markdownlint-enable MD033 -->
@ -73,7 +74,7 @@ If you're wondering how you could help, there are plenty of ways, e.g.:
- Promote it on your social networks. - Promote it on your social networks.
- Tell your friends about it by word-of-mouth. - Tell your friends about it by word-of-mouth.
- Write a press article on ocelot.social or contact the editorial office of your local news page or radio station. - Write a press article on ocelot.social or contact the editorial office of your local news page or radio station.
- Take a [good first issue](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) or issues that need help. Make sure to read [CONTRIBUTING.md](/CONTRIBUTING.md) first though. - Take a [good first issue](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) or issues that need help. Make sure to read [CONTRIBUTING.md](./CONTRIBUTING.md) first though.
- Testing and [reporting](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues/new/choose) bugs. - Testing and [reporting](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues/new/choose) bugs.
- Translating: Please [contact us](#contact). - Translating: Please [contact us](#contact).
- Reviewing and testing pull requests. - Reviewing and testing pull requests.
@ -249,7 +250,7 @@ $ yarn locales --fix
$ yarn test $ yarn test
``` ```
Check out our [contribution guideline](./CONTRIBUTING.md), too! Check out our [contribution guideline](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/CONTRIBUTING.md), too!
#### Developer Chat #### Developer Chat
@ -303,7 +304,7 @@ Locale Icons made by [Freepik](http://www.freepik.com/) from [www.flaticon.com](
Browser compatibility testing with [BrowserStack](https://www.browserstack.com/). Browser compatibility testing with [BrowserStack](https://www.browserstack.com/).
<!-- markdownlint-disable MD033 --> <!-- markdownlint-disable MD033 -->
<img alt="BrowserStack Logo" src=".gitbook/assets/browserstack-logo.svg" width="256"> <img alt="BrowserStack Logo" src="https://raw.githubusercontent.com/Ocelot-Social-Community/Ocelot-Social/master/.gitbook/assets/browserstack-logo.svg" width="256">
<!-- markdownlint-enable MD033 --> <!-- markdownlint-enable MD033 -->
### License ### License

View File

@ -1,7 +1,6 @@
# Table of contents # Table of contents
* [Introduction](README.md) * [Introduction](README.md)
* [Edit this Documentation](edit-this-documentation.md)
* [Neo4J](neo4j/README.md) * [Neo4J](neo4j/README.md)
* [Backend](backend/README.md) * [Backend](backend/README.md)
* [GraphQL](backend/graphql.md) * [GraphQL](backend/graphql.md)
@ -19,4 +18,5 @@
* [Contributing](CONTRIBUTING.md) * [Contributing](CONTRIBUTING.md)
* [Feature Specification](cypress/features.md) * [Feature Specification](cypress/features.md)
* [Code of Conduct](CODE_OF_CONDUCT.md) * [Code of Conduct](CODE_OF_CONDUCT.md)
* [Documentation](documentation.md)
* [License](LICENSE.md) * [License](LICENSE.md)

View File

@ -83,8 +83,8 @@ More details about our GraphQL playground and how to use it with ocelot.social c
Database indexes and constraints need to be created and upgraded when the database and the backend are running: Database indexes and constraints need to be created and upgraded when the database and the backend are running:
{% tabs %} ::: tabs
{% tab title="Docker" %} @tab:active Docker
```bash ```bash
# in main folder while docker-compose is running # in main folder while docker-compose is running
@ -102,8 +102,7 @@ $ docker compose exec backend /bin/sh -c "yarn prod:migrate init"
$ docker exec backend yarn run db:migrate up $ docker exec backend yarn run db:migrate up
``` ```
{% endtab %} @tab Without Docker
{% tab title="Without Docker" %}
```bash ```bash
# in folder backend/ while database is running # in folder backend/ while database is running
@ -116,16 +115,15 @@ yarn run db:migrate init
yarn run db:migrate up yarn run db:migrate up
``` ```
{% endtab %} :::
{% endtabs %}
#### Seed Database #### Seed Database
If you want your backend to return anything else than an empty response, you If you want your backend to return anything else than an empty response, you
need to seed your database: need to seed your database:
{% tabs %} ::: tabs
{% tab title="Docker" %} @tab:active Docker
In another terminal run: In another terminal run:
@ -147,8 +145,7 @@ $ docker exec backend yarn run db:migrate init
$ docker exec backend yarn run db:migrate up $ docker exec backend yarn run db:migrate up
``` ```
{% endtab %} @tab Without Docker
{% tab title="Without Docker" %}
Run: Run:
@ -164,16 +161,15 @@ To reset the database run:
$ yarn run db:reset $ yarn run db:reset
``` ```
{% endtab %} :::
{% endtabs %}
### Data migrations ### Data migrations
Although Neo4J is schema-less,you might find yourself in a situation in which Although Neo4J is schema-less,you might find yourself in a situation in which
you have to migrate your data e.g. because your data modeling has changed. you have to migrate your data e.g. because your data modeling has changed.
{% tabs %} ::: tabs
{% tab title="Docker" %} @tab:active Docker
Generate a data migration file: Generate a data migration file:
@ -190,8 +186,7 @@ To run the migration:
$ docker exec backend yarn run db:migrate up $ docker exec backend yarn run db:migrate up
``` ```
{% endtab %} @tab Without Docker
{% tab title="Without Docker" %}
Generate a data migration file: Generate a data migration file:
@ -208,16 +203,15 @@ To run the migration:
$ yarn run db:migrate up $ yarn run db:migrate up
``` ```
{% endtab %} :::
{% endtabs %}
## Testing ## Testing
**Beware**: We have no multiple database setup at the moment. We clean the **Beware**: We have no multiple database setup at the moment. We clean the
database after each test, running the tests will wipe out all your data! database after each test, running the tests will wipe out all your data!
{% tabs %} ::: tabs
{% tab title="Docker" %} @tab:active Docker
Run the unit tests: Run the unit tests:
@ -226,9 +220,7 @@ Run the unit tests:
$ docker exec backend yarn run test $ docker exec backend yarn run test
``` ```
{% endtab %} @tab Without Docker
{% tab title="Without Docker" %}
Run the unit tests: Run the unit tests:
@ -237,5 +229,4 @@ Run the unit tests:
$ yarn run test $ yarn run test
``` ```
{% endtab %} :::
{% endtabs %}

View File

@ -24,10 +24,10 @@
}, },
"dependencies": { "dependencies": {
"@babel/cli": "~7.8.4", "@babel/cli": "~7.8.4",
"@babel/core": "~7.9.0", "@babel/core": "^7.23.7",
"@babel/node": "~7.8.7", "@babel/node": "~7.8.7",
"@babel/plugin-proposal-throw-expressions": "^7.22.5", "@babel/plugin-proposal-throw-expressions": "^7.23.3",
"@babel/preset-env": "~7.22.20", "@babel/preset-env": "~7.23.8",
"@babel/register": "^7.9.0", "@babel/register": "^7.9.0",
"@sentry/node": "^5.15.4", "@sentry/node": "^5.15.4",
"apollo-cache-inmemory": "~1.6.5", "apollo-cache-inmemory": "~1.6.5",
@ -74,7 +74,7 @@
"metascraper-url": "^5.34.2", "metascraper-url": "^5.34.2",
"metascraper-video": "^5.33.5", "metascraper-video": "^5.33.5",
"metascraper-youtube": "^5.33.5", "metascraper-youtube": "^5.33.5",
"migrate": "^2.0.0", "migrate": "^2.0.1",
"mime-types": "^2.1.26", "mime-types": "^2.1.26",
"minimatch": "^3.0.4", "minimatch": "^3.0.4",
"mustache": "^4.2.0", "mustache": "^4.2.0",
@ -97,16 +97,14 @@
"@faker-js/faker": "7.6.0", "@faker-js/faker": "7.6.0",
"@types/jest": "^27.0.2", "@types/jest": "^27.0.2",
"@types/node": "^20.2.5", "@types/node": "^20.2.5",
"@typescript-eslint/eslint-plugin": "^5.57.1", "@typescript-eslint/eslint-plugin": "^5.62.0",
"@typescript-eslint/parser": "^5.57.1", "@typescript-eslint/parser": "^5.57.1",
"apollo-server-testing": "~2.11.0", "apollo-server-testing": "~2.11.0",
"chai": "~4.3.8",
"cucumber": "~6.0.5",
"eslint": "^8.37.0", "eslint": "^8.37.0",
"eslint-config-prettier": "^9.0.0", "eslint-config-prettier": "^9.1.0",
"eslint-config-standard": "^17.0.0", "eslint-config-standard": "^17.0.0",
"eslint-import-resolver-typescript": "^3.6.1", "eslint-import-resolver-typescript": "^3.6.1",
"eslint-plugin-import": "^2.27.5", "eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest": "^27.2.1", "eslint-plugin-jest": "^27.2.1",
"eslint-plugin-n": "^15.7.0", "eslint-plugin-n": "^15.7.0",
"eslint-plugin-prettier": "^4.2.1", "eslint-plugin-prettier": "^4.2.1",
@ -117,7 +115,7 @@
"prettier": "^2.8.7", "prettier": "^2.8.7",
"rosie": "^2.0.1", "rosie": "^2.0.1",
"ts-jest": "^27.0.5", "ts-jest": "^27.0.5",
"ts-node": "^10.9.1", "ts-node": "^10.9.2",
"typescript": "^4.9.4" "typescript": "^4.9.4"
}, },
"resolutions": { "resolutions": {

View File

@ -1,3 +1,3 @@
// this file is duplicated in `backend/src/constants/group` and `webapp/constants/group.js` // this file is duplicated in `backend/src/constants/group` and `webapp/constants/group.js`
export const DESCRIPTION_WITHOUT_HTML_LENGTH_MIN = 50 // with removed HTML tags export const DESCRIPTION_WITHOUT_HTML_LENGTH_MIN = 3 // with removed HTML tags
export const DESCRIPTION_EXCERPT_HTML_LENGTH = 250 // with removed HTML tags export const DESCRIPTION_EXCERPT_HTML_LENGTH = 250 // with removed HTML tags

View File

@ -1,35 +1,11 @@
import Factory, { cleanDatabase } from '../db/factories' import Factory, { cleanDatabase } from '../db/factories'
import { getDriver, getNeode } from '../db/neo4j' import { getDriver, getNeode } from '../db/neo4j'
import decode from './decode' import decode from './decode'
import encode from './encode'
const driver = getDriver() const driver = getDriver()
const neode = getNeode() const neode = getNeode()
// here is the decoded JWT token:
// {
// role: 'user',
// locationName: null,
// name: 'Jenny Rostock',
// about: null,
// avatar: 'https://s3.amazonaws.com/uifaces/faces/twitter/sasha_shestakov/128.jpg',
// id: 'u3',
// email: 'user@example.org',
// slug: 'jenny-rostock',
// iat: 1550846680,
// exp: 1637246680,
// aud: 'http://localhost:3000',
// iss: 'http://localhost:4000',
// sub: 'u3'
// }
// !!! if the token expires go into the GraphQL Playground in the browser at 'http://localhost:4000' with a running backend and a seeded Neo4j database
// now do the login mutation:
// mutation {
// login(email:"user@example.org", password:"1234")
// }
// replace this token here with the one you received as the result
export const validAuthorizationHeader =
'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6InUzIiwibmFtZSI6Ikplbm55IFJvc3RvY2siLCJzbHVnIjoiamVubnktcm9zdG9jayIsImlhdCI6MTYzNzY0NDMwMCwiZXhwIjoxNzAwNzU5NTAwLCJhdWQiOiJodHRwOi8vbG9jYWxob3N0OjMwMDAiLCJpc3MiOiJodHRwOi8vbG9jYWxob3N0OjQwMDAiLCJzdWIiOiJ1MyJ9.ispIfRfgkXuYoIhKx7x2jPxgvHDJVv1ogMycLmfUnsk'
beforeAll(async () => { beforeAll(async () => {
await cleanDatabase() await cleanDatabase()
}) })
@ -75,14 +51,8 @@ describe('decode', () => {
}) })
describe('given valid JWT Bearer token', () => { describe('given valid JWT Bearer token', () => {
beforeEach(() => {
authorizationHeader = validAuthorizationHeader
})
it('returns null', returnsNull)
describe('and corresponding user in the database', () => { describe('and corresponding user in the database', () => {
let user let user, validAuthorizationHeader
beforeEach(async () => { beforeEach(async () => {
user = await Factory.build( user = await Factory.build(
'user', 'user',
@ -99,10 +69,11 @@ describe('decode', () => {
email: 'user@example.org', email: 'user@example.org',
}, },
) )
validAuthorizationHeader = encode(await user.toJson())
}) })
it('returns user object without email', async () => { it('returns user object without email', async () => {
await expect(decode(driver, authorizationHeader)).resolves.toMatchObject({ await expect(decode(driver, validAuthorizationHeader)).resolves.toMatchObject({
role: 'user', role: 'user',
name: 'Jenny Rostock', name: 'Jenny Rostock',
id: 'u3', id: 'u3',
@ -113,7 +84,7 @@ describe('decode', () => {
it('sets `lastActiveAt`', async () => { it('sets `lastActiveAt`', async () => {
let user = await neode.first('User', { id: 'u3' }) let user = await neode.first('User', { id: 'u3' })
await expect(user.toJson()).resolves.not.toHaveProperty('lastActiveAt') await expect(user.toJson()).resolves.not.toHaveProperty('lastActiveAt')
await decode(driver, authorizationHeader) await decode(driver, validAuthorizationHeader)
user = await neode.first('User', { id: 'u3' }) user = await neode.first('User', { id: 'u3' })
await expect(user.toJson()).resolves.toMatchObject({ await expect(user.toJson()).resolves.toMatchObject({
lastActiveAt: expect.any(String), lastActiveAt: expect.any(String),
@ -129,7 +100,7 @@ describe('decode', () => {
await expect(user.toJson()).resolves.toMatchObject({ await expect(user.toJson()).resolves.toMatchObject({
lastActiveAt: '2019-10-03T23:33:08.598Z', lastActiveAt: '2019-10-03T23:33:08.598Z',
}) })
await decode(driver, authorizationHeader) await decode(driver, validAuthorizationHeader)
user = await neode.first('User', { id: 'u3' }) user = await neode.first('User', { id: 'u3' })
await expect(user.toJson()).resolves.toMatchObject({ await expect(user.toJson()).resolves.toMatchObject({
// should be a different time by now ;) // should be a different time by now ;)
@ -152,6 +123,15 @@ describe('decode', () => {
it('returns null', returnsNull) it('returns null', returnsNull)
}) })
describe('and NO corresponding user in the database', () => {
beforeEach(async () => {
await cleanDatabase()
authorizationHeader = validAuthorizationHeader
})
it('returns null', returnsNull)
})
}) })
}) })
}) })

View File

@ -328,15 +328,15 @@ describe('in mode', () => {
describe('description', () => { describe('description', () => {
describe('length without HTML', () => { describe('length without HTML', () => {
describe('less then 100 chars', () => { describe('less then 3 chars', () => {
it('throws error: "Description too short!"', async () => { it('throws error: "Description too short!"', async () => {
const { errors } = await mutate({ const { errors } = await mutate({
mutation: createGroupMutation(), mutation: createGroupMutation(),
variables: { variables: {
...variables, ...variables,
description: description:
'0123456789' + '0' +
'<a href="https://domain.org/0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789">0123456789</a>', '<a href="https://domain.org/0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789">0</a>',
}, },
}) })
expect(errors![0]).toHaveProperty('message', 'Description too short!') expect(errors![0]).toHaveProperty('message', 'Description too short!')
@ -2850,15 +2850,15 @@ describe('in mode', () => {
describe('description', () => { describe('description', () => {
describe('length without HTML', () => { describe('length without HTML', () => {
describe('less then 100 chars', () => { describe('less then 3 chars', () => {
it('throws error: "Description too short!"', async () => { it('throws error: "Description too short!"', async () => {
const { errors } = await mutate({ const { errors } = await mutate({
mutation: updateGroupMutation(), mutation: updateGroupMutation(),
variables: { variables: {
id: 'my-group', id: 'my-group',
description: description:
'0123456789' + '0' +
'<a href="https://domain.org/0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789">0123456789</a>', '<a href="https://domain.org/0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789">0</a>',
}, },
}) })
expect(errors![0]).toHaveProperty('message', 'Description too short!') expect(errors![0]).toHaveProperty('message', 'Description too short!')

File diff suppressed because it is too large Load Diff

View File

@ -14,9 +14,9 @@ The following features will be implemented. This gets done in three steps:
2. In a second step we will make our prototype publicly available with an advanced feature set including the technology and organizational structure to drive a bigger public social network. 2. In a second step we will make our prototype publicly available with an advanced feature set including the technology and organizational structure to drive a bigger public social network.
3. In a third step all the remaining features will be implemented to build the full product. 3. In a third step all the remaining features will be implemented to build the full product.
### User Account The implemented features can be found [here](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/e2e)
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/user_account) ### User Account
* Sign-up * Sign-up
* Agree to Data Privacy Statement * Agree to Data Privacy Statement
@ -34,8 +34,6 @@ The following features will be implemented. This gets done in three steps:
### User Profile ### User Profile
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/user_profile)
* Upload and Change Avatar * Upload and Change Avatar
* Upload and Change Profile Picture * Upload and Change Profile Picture
* Edit Social Media Accounts * Edit Social Media Accounts
@ -46,8 +44,6 @@ The following features will be implemented. This gets done in three steps:
### Dashboard ### Dashboard
[Clickdummy](https://preview.uxpin.com/24a2ab8adcd84f9a763d87ed27251351225e0ecd#/pages/99768919/simulate/sitemap?mode=i)
* Show Link to own Profile * Show Link to own Profile
* Show Friends Widget * Show Friends Widget
* Show Favorites Widget * Show Favorites Widget
@ -59,8 +55,6 @@ The following features will be implemented. This gets done in three steps:
### Posts ### Posts
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/post)
* Creating Posts * Creating Posts
* Persistent Links * Persistent Links
* Upload Teaser Picture for Post * Upload Teaser Picture for Post
@ -85,8 +79,6 @@ The following features will be implemented. This gets done in three steps:
### Notifications ### Notifications
[Cucumber features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/notifications)
* User @-mentionings * User @-mentionings
* Notify authors for comments * Notify authors for comments
* Administrative notifications to all users * Administrative notifications to all users
@ -108,8 +100,6 @@ The following features will be implemented. This gets done in three steps:
### Blacklist ### Blacklist
[Video](https://www.youtube.com/watch?v=-uDvvmN8hLQ)
* Blacklist Users * Blacklist Users
* Blacklist specific Terms * Blacklist specific Terms
* Blacklist Tags * Blacklist Tags
@ -117,8 +107,6 @@ The following features will be implemented. This gets done in three steps:
### Search ### Search
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/search)
* Search for Categories * Search for Categories
* Search for Tags * Search for Tags
* Fulltext Search * Fulltext Search
@ -238,8 +226,6 @@ Shows automatically related actions for existing post.
### Moderation ### Moderation
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/moderation)
* Report Button for users for doubtful Content * Report Button for users for doubtful Content
* Moderator Panel * Moderator Panel
* List of reported Content \(later replaced by User-Moderation\) * List of reported Content \(later replaced by User-Moderation\)
@ -250,8 +236,6 @@ Shows automatically related actions for existing post.
### Administration ### Administration
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/administration)
* Provide Admin-Interface to send Users Invite Code * Provide Admin-Interface to send Users Invite Code
* Static Pages for Data Privacy Statement ... * Static Pages for Data Privacy Statement ...
* Create, edit and delete Announcements * Create, edit and delete Announcements
@ -265,8 +249,6 @@ Shows automatically related actions for existing post.
### Internationalization ### Internationalization
[Cucumber Features](https://github.com/Ocelot-Social-Community/Ocelot-Social/tree/master/cypress/integration/internationalization)
* Frontend UI * Frontend UI
* Backend Error Messages * Backend Error Messages

View File

@ -1 +1,7 @@
CONFIGURATION=example # branding folder used for "docker compose up" run in deployment folder
CONFIGURATION=stage.ocelot.social
# used in "scripts/clusters.backup-multiple-servers.sh"
BACKUP_CONFIGURATIONS="stage.ocelot.social stage.wir.social"
# if '<= 0' no backups will be deleted
BACKUP_SAVED_BACKUPS_NUMBER=7

View File

@ -9,8 +9,6 @@
$ export DOCKER_DEFAULT_PLATFORM=linux/amd64 $ export DOCKER_DEFAULT_PLATFORM=linux/amd64
``` ```
For even more informations, see [Docker More Closely](#docker-more-closely)
### Docker Compose Override File For Apple M1 Platform ### Docker Compose Override File For Apple M1 Platform
For Docker compose `up` or `build` commands, you can use our Apple M1 override file that specifies the M1 platform: For Docker compose `up` or `build` commands, you can use our Apple M1 override file that specifies the M1 platform:
@ -27,7 +25,3 @@ $ docker compose -f docker-compose.ocelotsocial-branded.yml -f docker-compose.ap
# only once: init admin user and create indexes and constraints in Neo4j database # only once: init admin user and create indexes and constraints in Neo4j database
$ docker compose exec backend /bin/sh -c "yarn prod:migrate init" $ docker compose exec backend /bin/sh -c "yarn prod:migrate init"
``` ```
## Docker More Closely In Main Code
To get more informations about the Apple M1 platform and to analyze the Docker builds etc. you find our documentation in our main code, [here](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/DOCKER_MORE_CLOSELY.md).

View File

@ -11,7 +11,7 @@ $ minikube dashboard
This will give you an overview. Some of the steps below need some timing to make resources available to other dependent deployments. Keeping an eye on the dashboard is a great way to check that. This will give you an overview. Some of the steps below need some timing to make resources available to other dependent deployments. Keeping an eye on the dashboard is a great way to check that.
Follow the installation instruction for [Kubernetes with Helm](./kubernetes/README.md). Follow the installation instruction for [Kubernetes with Helm](./src/kubernetes/README.md).
If all the pods and services have settled and everything looks green in your If all the pods and services have settled and everything looks green in your
minikube dashboard, expose the services you want on your host system. minikube dashboard, expose the services you want on your host system.
@ -22,4 +22,4 @@ For example:
$ minikube service webapp --namespace=ocelotsocialnetwork $ minikube service webapp --namespace=ocelotsocialnetwork
# optionally # optionally
$ minikube service backend --namespace=ocelotsocialnetwork $ minikube service backend --namespace=ocelotsocialnetwork
``` ```

View File

@ -1,7 +1,7 @@
# Ocelot.Social Deploy And Rebranding # Ocelot.Social Deploy And Rebranding
[![Build Status Publish](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/actions/workflows/publish.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/actions) [![Build Status Publish](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/actions/workflows/publish.yml/badge.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/actions)
[![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/blob/LICENSE.md) [![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/Ocelot-Social-Community/Ocelot-Social-Deploy-Rebranding/blob/master/LICENSE.md)
[![Discord Channel](https://img.shields.io/discord/489522408076738561.svg)](https://discord.gg/AJSX9DCSUA) [![Discord Channel](https://img.shields.io/discord/489522408076738561.svg)](https://discord.gg/AJSX9DCSUA)
[![Open Source Helpers](https://www.codetriage.com/ocelot-social-community/ocelot-social-deploy-rebranding/badges/users.svg)](https://www.codetriage.com/ocelot-social-community/ocelot-social-deploy-rebranding) [![Open Source Helpers](https://www.codetriage.com/ocelot-social-community/ocelot-social-deploy-rebranding/badges/users.svg)](https://www.codetriage.com/ocelot-social-community/ocelot-social-deploy-rebranding)
@ -9,8 +9,8 @@ This repository is an in use template to rebrand, configure, and deploy [ocelot.
The forked original repository is [stage.ocelot.social](https://github.com/Ocelot-Social-Community/stage.ocelot.social). The forked original repository is [stage.ocelot.social](https://github.com/Ocelot-Social-Community/stage.ocelot.social).
<!-- markdownlint-disable MD033 --> <!-- markdownlint-disable MD033 -->
<p align="center"> <p style="text-align: center;">
<a href="https://ocelot.social" target="_blank"><img src="../webapp/static/img/custom/logo-squared.svg" alt="ocelot.social" width="40%" height="40%"></a> <a href="https://ocelot.social" target="_blank"><img src="https://raw.githubusercontent.com/Ocelot-Social-Community/Ocelot-Social/master/webapp/static/img/custom/logo-squared.svg" alt="ocelot.social" width="40%" height="40%"></a>
</p> </p>
<!-- markdownlint-enable MD033 --> <!-- markdownlint-enable MD033 -->
@ -39,16 +39,18 @@ Fork this repository to configure and rebrand it for your own [ocelot.social](ht
Write your own data into the main configuration file: Write your own data into the main configuration file:
- [package.json](/package.json) - [package.json](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/package.json)
Since all deployment methods described here depend on [Docker](https://docker.com) and [DockerHub](https://hub.docker.com), you need to create your own organisation on DockerHub and put its name in the [package.json](/package.json) file as your `dockerOrganisation`. Since all deployment methods described here depend on [Docker](https://docker.com) and [DockerHub](https://hub.docker.com), you need to create your own organisation on DockerHub and put its name in the [package.json](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/package.json) file as your `dockerOrganisation`.
### Configure And Branding ### Configure And Branding
The next step is: The next step is:
- [Set Environment Variables and Configurations](./deployment-values.md) - [Set Environment Variables and Configurations](./deployment-values.md)
<!-- markdown-link-check-disable -->
- [Configure And Branding](./configurations/stage.ocelot.social/branding/README.md) - [Configure And Branding](./configurations/stage.ocelot.social/branding/README.md)
<!-- markdown-link-check-enable -->
### Optional: Locally Testing Configuration And Branding ### Optional: Locally Testing Configuration And Branding
@ -71,7 +73,7 @@ For the maintenance page have a look in your browser at `http://localhost:5000/`
### Push Changes To GitHub ### Push Changes To GitHub
Before merging these changes into the "master" branch on your GitHub fork repository, you need to configure the GitHub repository secrets. This is necessary to [publish](/.github/workflows/publish.yml) the Docker images by pushing them via GitHub actions to repositories belonging to your DockerHub organisation. Before merging these changes into the "master" branch on your GitHub fork repository, you need to configure the GitHub repository secrets. This is necessary to [publish](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/.github/workflows/publish.yml) the Docker images by pushing them via GitHub actions to repositories belonging to your DockerHub organisation.
First, go to your DockerHub profile under `Account Settings` and click on the `Security` tab. There you create an access token called `<your-organisation>-access-token` and copy the token to a safe place. First, go to your DockerHub profile under `Account Settings` and click on the `Security` tab. There you create an access token called `<your-organisation>-access-token` and copy the token to a safe place.
@ -100,9 +102,9 @@ See the login details and browser addresses above.
### Deployment ### Deployment
Afterwards you can [deploy](/deployment/deployment.md) it on your server: Afterwards you can [deploy](./deployment.md) it on your server:
- [Kubernetes with Helm](/deployment/kubernetes/README.md) - [Kubernetes with Helm](./src/kubernetes/README.md)
## Developer Chat ## Developer Chat
@ -131,7 +133,6 @@ Browser compatibility testing with [BrowserStack](https://www.browserstack.com/)
## License ## License
See the [LICENSE](/LICENSE.md) file for license rights and limitations (MIT). See the [LICENSE](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/LICENSE.md) file for license rights and limitations (MIT).
We need `DOCKER_BUILDKIT=0` for this to work.
We need `DOCKER_BUILDKIT=0` for this to work.

View File

@ -2,9 +2,20 @@
When you introduce a new version and branding and deploy it on your network, you need to consider the following changes and actions: When you introduce a new version and branding and deploy it on your network, you need to consider the following changes and actions:
## Version >= 3.3.0 with 'ocelotDockerVersionTag' 3.3.0-XXX ## Version >= 3.1.3 with 'ocelotDockerVersionTag' 3.1.3-XXX
- We have the new option to configure DKIM for sent e-mails in environment variables (`.env` or `values.yaml`), see [deployment-values.md](deployment-values.md): - We have the new option to configure the default name of the Neo4j database to be used for operations and commands in environment variables (`.env`, `docker-compose.yml` or `values.yaml`).
For more details see [deployment-values.md](deployment-values.md):
```yaml
DBMS_DEFAULT_DATABASE: "graph.db"
```
The default value is `neo4j` if it is not set.
## Version >= 3.1.0 with 'ocelotDockerVersionTag' 3.1.0-555
- We have the new option to configure DKIM for sent e-mails in environment variables (`.env`, `docker-compose.yml` or `values.yaml`), see [deployment-values.md](deployment-values.md):
- `SMTP_DKIM_DOMAINNAME=` - `SMTP_DKIM_DOMAINNAME=`
- `SMTP_DKIM_KEYSELECTOR=` - `SMTP_DKIM_KEYSELECTOR=`
- `SMTP_DKIM_PRIVATKEY=` - `SMTP_DKIM_PRIVATKEY=`

View File

@ -17,7 +17,7 @@ Sometimes it is enough to create an SPF record in your DNS.
### DKIM ### DKIM
However, if you need DKIM authorization and verification, you must set the appropriate environment variables: However, if you need DKIM authorization and verification, you must set the appropriate environment variables in: `.env`, `docker-compose.yml` or Helm script `values.yaml`:
```bash ```bash
SMTP_DKIM_DOMAINNAME=<your e-mail sender domain> SMTP_DKIM_DOMAINNAME=<your e-mail sender domain>
@ -36,3 +36,23 @@ To create the private and public DKIM key, see here:
Information about the required PEM format can be found here: Information about the required PEM format can be found here:
<https://docs.progress.com/bundle/datadirect-hybrid-data-pipeline-installation-46/page/PEM-file-format.html> <https://docs.progress.com/bundle/datadirect-hybrid-data-pipeline-installation-46/page/PEM-file-format.html>
## Neo4j Database
We have several configuration options for our Neo4j database.
### DBMS_DEFAULT_DATABASE Default Database Name to be Used
If you need to set the default database name in Neo4j to be used for all operations and terminal commands like our backup scripts, you must set the appropriate environment variable in: `.env`, `docker-compose.yml` or Helm script `values.yaml`:
```yaml
DBMS_DEFAULT_DATABASE: "graph.db"
```
The default value is `neo4j` if it is not set.
As example see files:
- `neo4j/.env.template`
- `deployment/docker-compose.yml`
- `deployment/configurations/stage.ocelot.social/kubernetes/values.yaml.template`

View File

@ -4,14 +4,14 @@ Before you start the deployment you have to do preparations.
## Deployment Preparations ## Deployment Preparations
Since all deployment methods described here depend on [Docker](https://docker.com) and [DockerHub](https://hub.docker.com), you need to create your own organisation on DockerHub and put its name in the [package.json](/package.json) file as your `dockerOrganisation`. Since all deployment methods described here depend on [Docker](https://docker.com) and [DockerHub](https://hub.docker.com), you need to create your own organisation on DockerHub and put its name in the [package.json](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/package.json) file as your `dockerOrganisation`.
Read more details in the [main README](/README.md) under [Usage](/README.md#usage). Read more details in the [main README](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/README.md) under [Usage](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/README.md#usage).
## Deployment Methods ## Deployment Methods
You have the following options for a deployment: You have the following options for a deployment:
- [Kubernetes with Helm](./kubernetes/README.md) - [Kubernetes with Helm](./src/kubernetes/README.md)
## After Deployment ## After Deployment
@ -22,15 +22,15 @@ After the first deployment of the new network on your server, the database is in
***ATTENTION:*** When you are logged in for the first time, please change your (the admin's) e-mail to an existing one and change your password to a secure one !!! ***ATTENTION:*** When you are logged in for the first time, please change your (the admin's) e-mail to an existing one and change your password to a secure one !!!
## Use the Scripts ## Using the Scripts
To use all the scripts you have to set the variable `CONFIGURATION` in your terminal by entering: To use most of the scripts you have to set the variable `CONFIGURATION` in your terminal by entering:
```bash ```bash
# in deployment folder # in deployment folder
# set configuration name to folder name in 'configurations' folder (network name) # set configuration name to folder name in 'configurations' folder (network name)
$ export CONFIGURATION=`<your-configuration-name>` $ export CONFIGURATION=<your-configuration-name>
# to check this # to check this
$ echo $CONFIGURATION $ echo $CONFIGURATION
``` ```
@ -64,9 +64,13 @@ $ scripts/cluster.maintenance.sh on
$ scripts/cluster.maintenance.sh off $ scripts/cluster.maintenance.sh off
``` ```
### Backup Script ### Backup Scripts
To save a locale backup of the database and uploaded images: Save backups.
#### Single Backup
To save a local backup of the database and uploaded images:
```bash ```bash
# in deployment folder # in deployment folder
@ -76,3 +80,58 @@ $ scripts/cluster.backup.sh
``` ```
The backup will be saved into your network folders `backup` folder in a new folder with the date and time. The backup will be saved into your network folders `backup` folder in a new folder with the date and time.
#### Multiple Networks Backup
In order to save several network backups locally, you must define the configuration names of all networks in `.env`. The template for this is `deployment/.env.dist`:
```bash
# in the deployment folders '.env' set as example
BACKUP_CONFIGURATIONS="stage.ocelot.social stage.wir.social"
BACKUP_SAVED_BACKUPS_NUMBER=7
```
If `BACKUP_SAVED_BACKUPS_NUMBER <= 0` then no backups will be deleted.
To actually save all the backups run:
```bash
# in deployment folder
# save all backups listed in 'BACKUP_CONFIGURATIONS'
# delete all backups older then the 'BACKUP_SAVED_BACKUPS_NUMBER' newest ones
$ scripts/clusters.backup-multiple-servers.sh
```
The backups will be saved into your networks folders `backup` folder in a new folder with the date and time.
#### Automated Backups
⚠️ *Attention: Please check carefully whether really the oldest backups have been deleted. As shells on different systems behave differently with regard to the commands used in this script.*
Install automated backups by a [cron job](https://en.wikipedia.org/wiki/Cron).
Be aware of having the bash shell installed to run the script.
The environment variables for the automated backups are described above.
Installing a cron job by editing the cron table file:
```bash
# edit cron job table
$ crontab -e
```
In the editor add the line:
```bash
# in cron job table file
# set a cron job every night at 04am server time
# min hour day month weekday command
00 04 * * * /root/Ocelot-Social/deployment/scripts/clusters.backup-multiple-servers.sh >> /root/Ocelot-Social/deployment/backup-cron-job.log
```
This way the terminal output is written into a log file named `backup-cron-job.log` located in the deployment folder.
Be aware that the server datetime can differ from your local time.
Especially by the change between summer and winter time, because servers usually have UTC.
Find out the actual difference by running the command `date` on your server.

View File

@ -168,6 +168,9 @@ services:
# Uncomment following line for Neo4j Enterprise version instead of Community version # Uncomment following line for Neo4j Enterprise version instead of Community version
# TODO: clarify if that is the only thing needed to unlock the Enterprise version # TODO: clarify if that is the only thing needed to unlock the Enterprise version
# - NEO4J_ACCEPT_LICENSE_AGREEMENT=yes # - NEO4J_ACCEPT_LICENSE_AGREEMENT=yes
# set the name of the database to be used
# - NEO4J_dbms_default__database=graph.db
# - NEO4J_dbms_default__database=neo4j
# TODO: Remove the playground from production # TODO: Remove the playground from production
# bring the database in offline mode to export or load dumps # bring the database in offline mode to export or load dumps
# command: ["tail", "-f", "/dev/null"] # command: ["tail", "-f", "/dev/null"]

View File

@ -1,34 +1,44 @@
#!/bin/bash #!/bin/bash
# time stamp
printf "Backup started at:\n "
date
# base setup # base setup
SCRIPT_PATH=$(realpath $0) SCRIPT_PATH=$(realpath $0)
SCRIPT_DIR=$(dirname $SCRIPT_PATH) SCRIPT_DIR=$(dirname $SCRIPT_PATH)
# check CONFIGURATION # check CONFIGURATION
if [ -z ${CONFIGURATION} ]; then if [[ -z "$CONFIGURATION" ]]; then
echo "You must provide a `CONFIGURATION` via environment variable" echo "!!! You must provide a CONFIGURATION via environment variable !!!"
exit 1 exit 1
fi fi
printf " Cluster: %s\n" $CONFIGURATION
# configuration # configuration
KUBECONFIG=${KUBECONFIG:-${SCRIPT_DIR}/../configurations/${CONFIGURATION}/kubeconfig.yaml} KUBECONFIG=${KUBECONFIG:-${SCRIPT_DIR}/../configurations/${CONFIGURATION}/kubeconfig.yaml}
BACKUP_DATE=$(date "+%F_%H-%M-%S") BACKUP_DATE=$(date "+%F_%H-%M-%S")
BACKUP_FOLDER=${BACKUP_FOLDER:-${SCRIPT_DIR}/../configurations/${CONFIGURATION}/backup/${BACKUP_DATE}} BACKUP_FOLDER=${BACKUP_FOLDER:-${SCRIPT_DIR}/../configurations/${CONFIGURATION}/backup/${BACKUP_DATE}}
# create backup fodler printf "Backup folder name: %s\n" $BACKUP_DATE
# create backup folder
mkdir -p ${BACKUP_FOLDER} mkdir -p ${BACKUP_FOLDER}
# cluster maintenance mode on && Neo4j maintenance mode on # cluster maintenance mode on && Neo4j maintenance mode on
${SCRIPT_DIR}/cluster.neo4j.sh maintenance on ${SCRIPT_DIR}/cluster.neo4j.sh maintenance on
# database backup # database backup
echo "Dumping database ..."
kubectl --kubeconfig=${KUBECONFIG} -n default exec -it \ kubectl --kubeconfig=${KUBECONFIG} -n default exec -it \
$(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') \ $(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') \
-- neo4j-admin dump --database=graph.db --to=/var/lib/neo4j/$BACKUP_DATE-neo4j-dump -- neo4j-admin dump --to=/var/lib/neo4j/$BACKUP_DATE-neo4j-dump
# copy neo4j backup to local drive # copy neo4j backup to local drive
echo "Copying database to local file system ..."
kubectl --kubeconfig=${KUBECONFIG} cp \ kubectl --kubeconfig=${KUBECONFIG} cp \
default/$(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-neo4j |awk '{ print $1 }'):/var/lib/neo4j/$BACKUP_DATE-neo4j-dump $BACKUP_FOLDER/neo4j-dump default/$(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-neo4j |awk '{ print $1 }'):/var/lib/neo4j/$BACKUP_DATE-neo4j-dump $BACKUP_FOLDER/neo4j-dump
# copy image data # copy image data
echo "Copying public uploads to local file system ..."
kubectl --kubeconfig=${KUBECONFIG} cp \ kubectl --kubeconfig=${KUBECONFIG} cp \
default/$(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-backend |awk '{ print $1 }'):/app/public/uploads $BACKUP_FOLDER/public-uploads default/$(kubectl --kubeconfig=${KUBECONFIG} -n default get pods | grep ocelot-backend |awk '{ print $1 }'):/app/public/uploads $BACKUP_FOLDER/public-uploads

View File

@ -1,7 +1,5 @@
#!/bin/bash #!/bin/bash
# !!! never tested !!!
# base setup # base setup
SCRIPT_PATH=$(realpath $0) SCRIPT_PATH=$(realpath $0)
SCRIPT_DIR=$(dirname $SCRIPT_PATH) SCRIPT_DIR=$(dirname $SCRIPT_PATH)
@ -35,7 +33,7 @@ helm install \
--kubeconfig=${KUBECONFIG} \ --kubeconfig=${KUBECONFIG} \
--namespace cert-manager \ --namespace cert-manager \
--create-namespace \ --create-namespace \
--version v1.13.1 \ --version v1.13.2 \
--set installCRDs=true --set installCRDs=true
## install Ocelot with helm ## install Ocelot with helm

View File

@ -5,7 +5,7 @@ SCRIPT_PATH=$(realpath $0)
SCRIPT_DIR=$(dirname $SCRIPT_PATH) SCRIPT_DIR=$(dirname $SCRIPT_PATH)
# check CONFIGURATION # check CONFIGURATION
if [ -z ${CONFIGURATION} ]; then if [[ -z "$CONFIGURATION" ]]; then
echo "You must provide a `CONFIGURATION` via environment variable" echo "You must provide a `CONFIGURATION` via environment variable"
exit 1 exit 1
fi fi
@ -16,9 +16,11 @@ KUBECONFIG=${KUBECONFIG:-${SCRIPT_DIR}/../configurations/${CONFIGURATION}/kubeco
case $1 in case $1 in
on) on)
echo "Network maintenance: on"
kubectl --kubeconfig=${KUBECONFIG} patch ingress ingress-ocelot-webapp --type merge --patch-file ${SCRIPT_DIR}/../src/kubernetes/patches/patch.ingress.maintenance.on.yaml kubectl --kubeconfig=${KUBECONFIG} patch ingress ingress-ocelot-webapp --type merge --patch-file ${SCRIPT_DIR}/../src/kubernetes/patches/patch.ingress.maintenance.on.yaml
;; ;;
off) off)
echo "Network maintenance: off"
kubectl --kubeconfig=${KUBECONFIG} patch ingress ingress-ocelot-webapp --type merge --patch-file ${SCRIPT_DIR}/../src/kubernetes/patches/patch.ingress.maintenance.off.yaml kubectl --kubeconfig=${KUBECONFIG} patch ingress ingress-ocelot-webapp --type merge --patch-file ${SCRIPT_DIR}/../src/kubernetes/patches/patch.ingress.maintenance.off.yaml
;; ;;
*) *)

View File

@ -5,7 +5,7 @@ SCRIPT_PATH=$(realpath $0)
SCRIPT_DIR=$(dirname $SCRIPT_PATH) SCRIPT_DIR=$(dirname $SCRIPT_PATH)
# check CONFIGURATION # check CONFIGURATION
if [ -z ${CONFIGURATION} ]; then if [[ -z "$CONFIGURATION" ]]; then
echo "You must provide a `CONFIGURATION` via environment variable" echo "You must provide a `CONFIGURATION` via environment variable"
exit 1 exit 1
fi fi
@ -21,20 +21,24 @@ case $1 in
${SCRIPT_DIR}/cluster.maintenance.sh on ${SCRIPT_DIR}/cluster.maintenance.sh on
# set Neo4j in offline mode (maintenance) # set Neo4j in offline mode (maintenance)
echo "Neo4j maintenance: on"
kubectl --kubeconfig=${KUBECONFIG} get deployment ocelot-neo4j -o json \ kubectl --kubeconfig=${KUBECONFIG} get deployment ocelot-neo4j -o json \
| jq '.spec.template.spec.containers[] += {"command": ["tail", "-f", "/dev/null"]}' \ | jq '.spec.template.spec.containers[] += {"command": ["tail", "-f", "/dev/null"]}' \
| kubectl --kubeconfig=${KUBECONFIG} apply -f - | kubectl --kubeconfig=${KUBECONFIG} apply -f -
# wait for the container to restart # wait for the container to restart
echo "Wait 60s ..."
sleep 60 sleep 60
;; ;;
off) off)
# set Neo4j in online mode # set Neo4j in online mode
echo "Neo4j maintenance: off"
kubectl --kubeconfig=${KUBECONFIG} get deployment ocelot-neo4j -o json \ kubectl --kubeconfig=${KUBECONFIG} get deployment ocelot-neo4j -o json \
| jq 'del(.spec.template.spec.containers[].command)' \ | jq 'del(.spec.template.spec.containers[].command)' \
| kubectl --kubeconfig=${KUBECONFIG} apply -f - | kubectl --kubeconfig=${KUBECONFIG} apply -f -
# wait for the container to restart # wait for the container to restart
echo "Wait 60s ..."
sleep 60 sleep 60
# maintenance mode off # maintenance mode off

View File

@ -0,0 +1,91 @@
#!/bin/bash
# time stamp
printf "\n\nMultiple backups started at:\n "
date
# base setup
SCRIPT_PATH=$(realpath $0)
SCRIPT_DIR=$(dirname $SCRIPT_PATH)
# save old CONFIGURATION for later reset
export SAVE_CONFIGURATION=$CONFIGURATION
# export all variables in "../.env"
set -a
source ${SCRIPT_DIR}/../.env
set +a
# check BACKUP_CONFIGURATIONS
if [[ -z "$BACKUP_CONFIGURATIONS" ]]; then
#%! echo "You must provide a BACKUP_CONFIGURATIONS via environment variable"
printf "!!! You must provide a BACKUP_CONFIGURATIONS via environment variable !!!\n"
exit 1
fi
# check BACKUP_SAVED_BACKUPS_NUMBER
if [[ -z ${BACKUP_SAVED_BACKUPS_NUMBER} ]]; then
#%! echo "You must provide a BACKUP_SAVED_BACKUPS_NUMBER via environment variable"
printf "!!! You must provide a BACKUP_SAVED_BACKUPS_NUMBER via environment variable !!!\n"
exit 1
fi
# convert configurations to array
IFS=' ' read -a CONFIGURATIONS_ARRAY <<< "$BACKUP_CONFIGURATIONS"
# display the clusters
printf "Backup the clusters:\n"
for i in "${CONFIGURATIONS_ARRAY[@]}"
do
echo " $i"
done
# deleting backups?
if (( BACKUP_SAVED_BACKUPS_NUMBER >= 1 )); then
printf "Keep the last %d backups for all networks.\n" $BACKUP_SAVED_BACKUPS_NUMBER
else
echo "!!! ATTENTION: No backups are deleted !!!"
fi
echo "Cancel by ^C. You have 15 seconds"
# wait for the admin to react
sleep 15
printf "\n"
for i in "${CONFIGURATIONS_ARRAY[@]}"
do
export CONFIGURATION=$i
# individual cluster backup
${SCRIPT_DIR}/cluster.backup.sh
# deleting backups?
if (( BACKUP_SAVED_BACKUPS_NUMBER >= 1 )); then
# delete all oldest backups, but leave the last BACKUP_SAVED_BACKUPS_NUMBER
keep=$BACKUP_SAVED_BACKUPS_NUMBER
path="$SCRIPT_DIR/../configurations/$CONFIGURATION/backup/"
cd $path
printf "In\n '$path'\n remove:\n"
while [ `ls -1 | wc -l` -gt $keep ]; do
oldest=`ls -c1 | sort -n | head -1`
printf " %s\n" $oldest
rm -rf $oldest
done
printf "Keep the last %d backups:\n" $BACKUP_SAVED_BACKUPS_NUMBER
ls -c1 | sort -n | awk '{print " " $0}'
cd $SCRIPT_DIR
else
echo "!!! ATTENTION: No backups are deleted !!!"
fi
printf "\n"
done
# reset CONFIGURATION to old
export CONFIGURATION=$SAVE_CONFIGURATION
echo "Reset to CONFIGURATION=$CONFIGURATION"

View File

@ -137,7 +137,7 @@ $ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-neo4j
# bash: enter bash of Neo4j # bash: enter bash of Neo4j
$ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') -- bash $ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') -- bash
# generate Dump # generate Dump
neo4j% neo4j-admin dump --database=graph.db --to=/var/lib/neo4j/$(date +%F)-neo4j-dump neo4j% neo4j-admin dump --to=/var/lib/neo4j/$(date +%F)-neo4j-dump
# exit bash # exit bash
neo4j% exit neo4j% exit
@ -145,6 +145,9 @@ neo4j% exit
$ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') -- ls $ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-neo4j | awk '{ print $1 }') -- ls
``` ```
If you need a specific database name, add the option `--database=<name>` to the command `neo4j-admin dump`.
To find out the default database name, see the [Neo4j readme](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/neo4j/README.md).
Lets copy the dump backup Lets copy the dump backup
```bash ```bash

View File

@ -49,6 +49,49 @@ Skip `Patch & Minor Version Upgrades` for now.
You don't need a 1-click app. Our helmet script will install the required NGINXs. You don't need a 1-click app. Our helmet script will install the required NGINXs.
Therefore, skip this step as well. Therefore, skip this step as well.
For a 1-click Kubernetes Dashboard or alternatives, follow the next steps.
## Install Kubernetes Dashboard
We recommend installing a Kubernetes Dashboard, as DigitalOcean no longer offers a pre-installed dashboard.
- 1-click-deployment of [Kubernetes Dashboard on DigitalOcean marketplace](https://marketplace.digitalocean.com/apps/kubernetes-dashboard)
There you will also find a section entitled `Getting Started`, which describes how you can log in from your local computer.
Very short description:
### In your DigitalOcean Account
For authentication, download the current cluster configuration file from DigitalOcean.
### In Terminal
Set the context of the cluster by command:
```bash
$ kubectl config use-context <context-name>
```
Port-forward the Kubernetes Dashboard to your local machine:
```bash
# save pod name
$ export POD_NAME=$(kubectl get pods -n kubernetes-dashboard -l "app.kubernetes.io/name=kubernetes-dashboard,app.kubernetes.io/instance=kubernetes-dashboard" -o jsonpath="{.items[0].metadata.name}")
# forward port
$ kubectl -n kubernetes-dashboard port-forward $POD_NAME 8443:8443
```
### Log-In to Kubernetes Dashboard
Access the URL in your local web browser at `https://127.0.0.1:8443/`, and log in using your Kubernetes cluster credentials downloaded config file. You may encounter a certificate warning, so make sure to override it.
## Alternatives to Kubernetes Dashboard
DigitalOcean has a website about Kubernetes Dashboard and alternatives:
- <https://www.digitalocean.com/community/conceptual-articles/kubernetes-visualization-tools?mkt_tok=MTEzLURUTi0yNjYAAAGQ0YS-wbZaWn5th-m86-fM7vgiLvxNipWpAsUrgd2z4YgiMB0aRgCIDYEiC0Y2c0H9tBsICZQ5ORKgssOgeSjOKSEfN3i7xUpzqXbdZiYxNL2Q>
## DNS Configuration ## DNS Configuration
There are the following two ways to set up the DNS. There are the following two ways to set up the DNS.
@ -68,17 +111,17 @@ Take one of the IPs of perhaps two or more droplets in your cluster from the lis
To understand what makes sense to do when managing your DNS with DigitalOcean, you need to know how DNS works: To understand what makes sense to do when managing your DNS with DigitalOcean, you need to know how DNS works:
DNS means `Domain Name System`. It resolves domains like `example.com` into an IP like `123.123.123.123`. DNS means `Domain Name System`. It resolves domains like `example.com` into an IP like `123.123.123.123`.
DigitalOcean is not a domain registrar, but provides a DNS management service. If you use DigitalOcean's DNS management service, you can configure [your cluster](/deployment/kubernetes/README.md#dns) to always resolve the domain to the correct IP and automatically update it for that. DigitalOcean is not a domain registrar, but provides a DNS management service. If you use DigitalOcean's DNS management service, you can configure [your cluster](./README.md#dns) to always resolve the domain to the correct IP and automatically update it for that.
The IPs of the DigitalOcean machines are not necessarily stable, so the cluster's DNS service will update the DNS records managed by DigitalOcean to the new IP as needed. The IPs of the DigitalOcean machines are not necessarily stable, so the cluster's DNS service will update the DNS records managed by DigitalOcean to the new IP as needed.
***CAUTION:** If you are using an external DNS, you currently have to do this manually, which can cause downtime.* ***CAUTION:** If you are using an external DNS, you currently have to do this manually, which can cause downtime.*
## Deploy ## Deploy
Yeah, you're done here. Back to [Deployment with Helm for Kubernetes](/deployment/src/kubernetes/README.md). Yeah, you're done here. Back to [Deployment with Helm for Kubernetes](./README.md).
## Backups On DigitalOcean ## Backups On DigitalOcean
You can and should do [backups](/deployment/kubernetes/Backup.md) with Kubernetes for sure. You can and should do [backups](./Backup.md) with Kubernetes for sure.
Additional to backup and copying the Neo4j database dump and the backend images you can do a volume snapshot on DigitalOcean at the moment you have the database in sleep mode. Additional to backup and copying the Neo4j database dump and the backend images you can do a volume snapshot on DigitalOcean at the moment you have the database in sleep mode.

View File

@ -9,7 +9,7 @@ Please contact us if you are interested in options not listed below.
Managed Kubernetes: Managed Kubernetes:
- [DigitalOcean](/deployment/src/kubernetes/DigitalOcean.md) - [DigitalOcean](./DigitalOcean.md)
## Configuration ## Configuration
@ -76,7 +76,7 @@ $ helm install \
cert-manager jetstack/cert-manager \ cert-manager jetstack/cert-manager \
--namespace cert-manager \ --namespace cert-manager \
--create-namespace \ --create-namespace \
--version v1.13.1 \ --version v1.13.2 \
--set installCRDs=true --set installCRDs=true
# or kubeconfig.yaml in your repo, then adjust # or kubeconfig.yaml in your repo, then adjust
$ helm install \ $ helm install \
@ -84,7 +84,7 @@ $ helm install \
--kubeconfig ./kubeconfig.yaml \ --kubeconfig ./kubeconfig.yaml \
--namespace cert-manager \ --namespace cert-manager \
--create-namespace \ --create-namespace \
--version v1.13.1 \ --version v1.13.2 \
--set installCRDs=true --set installCRDs=true
``` --> ``` -->
@ -165,7 +165,7 @@ $ doctl compute firewall get <ID> --context <context-name>
***ATTENTION:** This seems not to work at all so we leave it away at the moment* ***ATTENTION:** This seems not to work at all so we leave it away at the moment*
***TODO:** I thought this is necessary if we use the DigitalOcean DNS management service? See [Manage DNS With DigitalOcean](/deployment/kubernetes/DigitalOcean.md#manage-dns-with-digitalocean)* ***TODO:** I thought this is necessary if we use the DigitalOcean DNS management service? See [Manage DNS With DigitalOcean](./DigitalOcean.md#manage-dns-with-digitalocean)*
This chart is only necessary (recommended is more precise) if you run DigitalOcean without load balancer. This chart is only necessary (recommended is more precise) if you run DigitalOcean without load balancer.
You need to generate an access token with read + write for the `dns.values.yaml` at <https://cloud.digitalocean.com/account/api/tokens> and fill it in. You need to generate an access token with read + write for the `dns.values.yaml` at <https://cloud.digitalocean.com/account/api/tokens> and fill it in.
@ -280,9 +280,9 @@ helm uninstall ocelot \
## Backups ## Backups
You can and should do [backups](/deployment/kubernetes/Backup.md) with Kubernetes for sure. You can and should do [backups](./Backup.md) with Kubernetes for sure.
## Error Reporting <!-- ## Error Reporting
We use [Sentry](https://github.com/getsentry/sentry) for error reporting in both We use [Sentry](https://github.com/getsentry/sentry) for error reporting in both
our backend and web frontend. You can either use a hosted or a self-hosted our backend and web frontend. You can either use a hosted or a self-hosted
@ -297,7 +297,7 @@ If you are lucky enough to have a kubernetes cluster with the required hardware
support, try this [helm chart](https://github.com/helm/charts/tree/master/stable/sentry). support, try this [helm chart](https://github.com/helm/charts/tree/master/stable/sentry).
On our kubernetes cluster we get "mult-attach" errors for persistent volumes. On our kubernetes cluster we get "mult-attach" errors for persistent volumes.
Apparently DigitalOcean's kubernetes clusters do not fulfill the requirements. Apparently DigitalOcean's kubernetes clusters do not fulfill the requirements. -->
## Kubernetes Commands (Without Helm) To Deploy New Docker Images To A Kubernetes Cluster ## Kubernetes Commands (Without Helm) To Deploy New Docker Images To A Kubernetes Cluster

View File

@ -20,4 +20,5 @@ data:
NEO4J_dbms_security_procedures_unrestricted: "{{ .Values.NEO4J.DBMS_SECURITY_PROCEDURES_UNRESTRICTED }}" NEO4J_dbms_security_procedures_unrestricted: "{{ .Values.NEO4J.DBMS_SECURITY_PROCEDURES_UNRESTRICTED }}"
NEO4J_dbms_allow__format__migration: "true" NEO4J_dbms_allow__format__migration: "true"
NEO4J_dbms_allow__upgrade: "true" NEO4J_dbms_allow__upgrade: "true"
NEO4J_apoc_import_file_enabled: "{{ .Values.NEO4J.APOC_IMPORT_FILE_ENABLED }}" NEO4J_dbms_default__database: "{{ .Values.NEO4J.DBMS_DEFAULT_DATABASE }}"
NEO4J_apoc_import_file_enabled: "{{ .Values.NEO4J.APOC_IMPORT_FILE_ENABLED }}"

View File

@ -23,13 +23,12 @@ CAUTION: It seems that the behaviour of DigitalOcean has changed and the load ba
And to create a load balancer costs money. Please refine the following documentation if required. And to create a load balancer costs money. Please refine the following documentation if required.
{% endhint %} {% endhint %}
{% tabs %} ::: tabs
{% tab title="Without Load Balancer" %} @tab:active Without Load Balancer
A solution without a load balance you can find [here](../no-loadbalancer/README.md). A solution without a load balance you can find [here](../no-loadbalancer/README.md).
{% endtab %} @tab With DigitalOcean Load Balancer
{% tab title="With DigitalOcean Load Balancer" %}
{% hint style="info" %} {% hint style="info" %}
CAUTION: It seems that the behaviour of DigitalOcean has changed and the load balancer is not created automatically anymore. CAUTION: It seems that the behaviour of DigitalOcean has changed and the load balancer is not created automatically anymore.
@ -44,8 +43,7 @@ address. On DigitalOcean, this is how it should look like:
If the load balancer isn't created automatically you have to create it your self on DigitalOcean under Networks. If the load balancer isn't created automatically you have to create it your self on DigitalOcean under Networks.
In case you don't need a DigitalOcean load balancer (which costs money by the way) have a look in the tab `Without Load Balancer`. In case you don't need a DigitalOcean load balancer (which costs money by the way) have a look in the tab `Without Load Balancer`.
{% endtab %} :::
{% endtabs %}
Check the ingress server is working correctly: Check the ingress server is working correctly:

View File

@ -79,8 +79,8 @@ $ kubectl -n ocelot-social get pods
$ kubectl cp ./neo4j-backup human-connection/<POD-ID>:/root/ $ kubectl cp ./neo4j-backup human-connection/<POD-ID>:/root/
$ kubectl -n ocelot-social exec -it <POD-ID> bash $ kubectl -n ocelot-social exec -it <POD-ID> bash
# Once you're in the pod restore the backup and overwrite the default database # Once you're in the pod restore the backup and overwrite the default database
# called `graph.db` with `--force`. # called `neo4j` with `--force`.
# This will delete all existing data in database `graph.db`! # This will delete all existing data in database `neo4j`!
> neo4j-admin load --from=/root/neo4j-backup --force > neo4j-admin load --from=/root/neo4j-backup --force
> exit > exit
``` ```

View File

@ -114,9 +114,12 @@ services:
- NEO4J_dbms_security_procedures_unrestricted=algo.*,apoc.* - NEO4J_dbms_security_procedures_unrestricted=algo.*,apoc.*
- NEO4J_dbms_allow__format__migration=true - NEO4J_dbms_allow__format__migration=true
- NEO4J_dbms_allow__upgrade=true - NEO4J_dbms_allow__upgrade=true
# Uncomment following line for Neo4j Enterprise version instead of Community version # uncomment following line for Neo4j Enterprise version instead of Community version
# TODO: clarify if that is the only thing needed to unlock the Enterprise version # TODO: clarify if that is the only thing needed to unlock the Enterprise version
# - NEO4J_ACCEPT_LICENSE_AGREEMENT=yes # - NEO4J_ACCEPT_LICENSE_AGREEMENT=yes
# set the name of the database to be used
# - NEO4J_dbms_default__database=graph.db
# - NEO4J_dbms_default__database=neo4j
# TODO: Remove the playground from production # TODO: Remove the playground from production
# bring the database in offline mode to export or load dumps # bring the database in offline mode to export or load dumps
# command: ["tail", "-f", "/dev/null"] # command: ["tail", "-f", "/dev/null"]

View File

@ -1,4 +1,6 @@
# Edit this Documentation # Documentation
## Edit this Documentation
Find the [**table of contents** for this documentation on GitHub](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/SUMMARY.md) and navigate to the file you need to update. Find the [**table of contents** for this documentation on GitHub](https://github.com/Ocelot-Social-Community/Ocelot-Social/blob/master/SUMMARY.md) and navigate to the file you need to update.
@ -10,15 +12,15 @@ If you are ready, fill in the **Propose file change** at the end of the webpage.
After that you have to compare your change branch to our `master` branch with a pull request. Here make a comment which issue you have fixed. (If you are working on one of our [open issues](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues) please include the number.) After that you have to compare your change branch to our `master` branch with a pull request. Here make a comment which issue you have fixed. (If you are working on one of our [open issues](https://github.com/Ocelot-Social-Community/Ocelot-Social/issues) please include the number.)
## Markdown your documentation ### Markdown your documentation
To design your documentation see the syntax description at GitBook: To design your documentation see the syntax description at GitBook:
[https://toolchain.gitbook.com/syntax/markdown.html](https://toolchain.gitbook.com/syntax/markdown.html) [https://toolchain.gitbook.com/syntax/markdown.html](https://toolchain.gitbook.com/syntax/markdown.html)
### Some quick Examples #### Some quick Examples
#### Headlines ##### Headlines
```markdown ```markdown
# Main Headline # Main Headline
@ -26,21 +28,19 @@ To design your documentation see the syntax description at GitBook:
### Small Headlines ### Small Headlines
``` ```
#### Tabs ##### Tabs
```markdown ```markdown
{% tabs %} ::: tabs
{% tab title="XXX" %} @tab:active First tab's title <!-- this tab is setactive -->
XXX
{% endtab %} @tab Second tab's title
{% tab title="XXX" %}
XXX :::
{% endtab %}
{% endtabs %}
``` ```
#### Commands
##### Commands
~~~markdown ~~~markdown
```<LANGUAGE> (for text highlighting) ```<LANGUAGE> (for text highlighting)
@ -48,33 +48,34 @@ XXX
``` ```
~~~ ~~~
#### Links ##### Links
```markdown ```markdown
[XXX](https://XXX) [XXX](https://XXX)
``` ```
For the documentation to work in both frameworks - Github and Vuepress - please use absolute path for Github internal documentation links (e.g. /README.md over ../../README.mdetc.)
#### Screenshots or other Images ##### Screenshots or other Images
```markdown ```markdown
![XXX](https://XXX) ![XXX](https://XXX)
``` ```
#### Hints for ToDos ##### Hints for ToDos
```markdown ```markdown
{% hint style="info" %} TODO: XXX {% endhint %} {% hint style="info" %} TODO: XXX {% endhint %}
``` ```
## Host the Screenshots ### Host the Screenshots
### Host on Ocelot-Social \(GitHub\) Repository #### Host on Ocelot-Social \(GitHub\) Repository
{% hint style="info" %} {% hint style="info" %}
TODO: How to host on Ocelot-Social \(GitHub\) repository ... TODO: How to host on Ocelot-Social \(GitHub\) repository ...
{% endhint %} {% endhint %}
### Quick Solution #### Quick Solution
To quickly host the screenshots go to: To quickly host the screenshots go to:
@ -88,27 +89,41 @@ Right click on it and choose kind of **Open link in new tab**.
Copy the URL and paste it were you need it. Copy the URL and paste it were you need it.
## Screenshot Modification ### Screenshot Modification
### Add an Arrow or some other Marking Stuff #### Add an Arrow or some other Marking Stuff
{% tabs %} ::: tabs
{% tab title="macOS" %} @tab:active macOS
#### In the Preview App ##### In the Preview App
Got to: **Menu** + **Tools** \(GER: Werkzeuge\) + **Annotate** \(GER: Anmerkungen\) + etc. Got to: **Menu** + **Tools** \(GER: Werkzeuge\) + **Annotate** \(GER: Anmerkungen\) + etc.
{% endtab %}
{% tab title="Windows" %} @tab Windows
{% hint style="info" %} {% hint style="info" %}
TODO: How to modify screenshots in Windows ... TODO: How to modify screenshots in Windows ...
{% endhint %} {% endhint %}
{% endtab %} {% endtab %}
{% tab title="Linux" %} @tab Linux
{% hint style="info" %} {% hint style="info" %}
TODO: How to modify screenshots in Linux ... TODO: How to modify screenshots in Linux ...
{% endhint %} {% endhint %}
{% endtab %} :::
{% endtabs %}
## Deploy this Documentation
TODO
```bash
# set configured Node version
nvm use
# install Vuepress
npm install
# run vuepress
npm run docs:dev
```

View File

@ -1,2 +1,3 @@
NEO4J_USERNAME=neo4j NEO4J_USERNAME=neo4j
NEO4J_PASSWORD=letmein NEO4J_PASSWORD=letmein
# DBMS_DEFAULT_DATABASE="neo4j"

View File

@ -1,4 +1,4 @@
# Neo4J # Neo4j 4.4
Human Connection is a social network. Using a graph based database which can Human Connection is a social network. Using a graph based database which can
model nodes and edges natively - a network - feels like an obvious choice. We model nodes and edges natively - a network - feels like an obvious choice. We
@ -16,8 +16,7 @@ docker-compose up
``` ```
You can access Neo4J through [http://localhost:7474/](http://localhost:7474/) You can access Neo4J through [http://localhost:7474/](http://localhost:7474/)
for an interactive cypher shell and a visualization of the graph. for an interactive Cypher shell and a visualization of the graph.
## Installation Without Docker ## Installation Without Docker
@ -51,7 +50,7 @@ in `backend/.env`.
Start Neo4J and confirm the database is running at [http://localhost:7474](http://localhost:7474). Start Neo4J and confirm the database is running at [http://localhost:7474](http://localhost:7474).
## Operations on Neo4j ## Operations on Neo4j 4.4
### Docker or Docker Compose ### Docker or Docker Compose
@ -68,13 +67,15 @@ To create a dump in Neo4j running in a Docker container:
# connect to the Docker containers Neo4j terminal # connect to the Docker containers Neo4j terminal
$ docker exec -it neo4j bash $ docker exec -it neo4j bash
# generate Dump # generate Dump
neo4j% neo4j-admin dump --database=graph.db --to=/var/lib/neo4j/$(date +%F)-neo4j-dump neo4j% neo4j-admin dump --to=/var/lib/neo4j/$(date +%F)-neo4j-dump
# exit bash # exit bash
neo4j% exit neo4j% exit
# copy the dump out of the running Docker container # copy the dump out of the running Docker container
$ docker cp <docker-image-name('neo4j')>:/var/lib/neo4j/neo4j-dump <local-folder-path>/$(date +%F)-neo4j-dump $ docker cp <docker-image-name('neo4j')>:/var/lib/neo4j/neo4j-dump <local-folder-path>/$(date +%F)-neo4j-dump
``` ```
If you need a specific database name, add the option `--database=<name>` to the command `neo4j-admin dump`.
### Import Neo4j Dump ### Import Neo4j Dump
To import a dump into Neo4j running in a Docker container: To import a dump into Neo4j running in a Docker container:
@ -88,11 +89,14 @@ $ docker cp <local-folder-path>/neo4j-dump <docker-image-name('neo4j')>:/var/lib
# connect to the Docker containers Neo4j terminal # connect to the Docker containers Neo4j terminal
$ docker exec -it neo4j bash $ docker exec -it neo4j bash
# to load the dump into the database we need the following command in this terminal # to load the dump into the database we need the following command in this terminal
neo4j% neo4j-admin load --expand-commands --database=graph.db --from /var/lib/neo4j/$(date +%F)-neo4j-dump --force neo4j% neo4j-admin load --from /var/lib/neo4j/$(date +%F)-neo4j-dump --force
# leave the terminal by entering # leave the terminal by entering
neo4j% exit neo4j% exit
``` ```
If you need a specific database name, add the option `--database=<name>` to the command `neo4j-admin load`.
To find out the default database name, see below.
## Commands ## Commands
Here we describe some rarely used Cypher commands for Neo4j that are needed from time to time: Here we describe some rarely used Cypher commands for Neo4j that are needed from time to time:
@ -143,7 +147,7 @@ $ kubectl -n default exec -it $(kubectl -n default get pods | grep ocelot-backen
***Cypher commands to show indexes and constraints*** ***Cypher commands to show indexes and constraints***
```bash ```bash
# in browser command line or cypher shell # in browser command line or Cypher shell
# show all indexes and constraints # show all indexes and constraints
$ :schema $ :schema
@ -158,7 +162,7 @@ $ CALL db.constraints();
***Cypher commands to create and drop indexes and constraints*** ***Cypher commands to create and drop indexes and constraints***
```bash ```bash
# in browser command line or cypher shell # in browser command line or Cypher shell
# create indexes # create indexes
$ CALL db.index.fulltext.createNodeIndex("post_fulltext_search",["Post"],["title", "content"]); $ CALL db.index.fulltext.createNodeIndex("post_fulltext_search",["Post"],["title", "content"]);
@ -171,3 +175,21 @@ $ DROP CONSTRAINT ON ( image:Image ) ASSERT image.url IS UNIQUE
# drop all indexes and constraints # drop all indexes and constraints
$ CALL apoc.schema.assert({},{},true) YIELD label, key RETURN * ; $ CALL apoc.schema.assert({},{},true) YIELD label, key RETURN * ;
``` ```
### Database Management Commands
***Cypher commands to manage databases***
```bash
# in browser command line or Cypher shell
# show the default database
$ SHOW DEFAULT DATABASE
# show all databases
$ SHOW DATABASES
```
To set the default database by configuration, use `NEO4J_dbms_default__database` as an environment variable when starting Neo4j 4.4, see [Docker specific configuration settings](<https://neo4j.com/docs/operations-manual/4.4/docker/ref-settings/>).
If a database with this name does not exist, an empty database with this name is created and all other databases remain.
You can switch back to an existing database without damaging it.

14403
package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@ -4,7 +4,6 @@
"description": "Free and open source software program code available to run social networks.", "description": "Free and open source software program code available to run social networks.",
"author": "ocelot.social Community", "author": "ocelot.social Community",
"license": "MIT", "license": "MIT",
"private": false,
"repository": { "repository": {
"type": "git", "type": "git",
"url": "https://github.com/Ocelot-Social-Community/Ocelot-Social.git" "url": "https://github.com/Ocelot-Social-Community/Ocelot-Social.git"
@ -27,24 +26,24 @@
"scripts": { "scripts": {
"db:seed": "cd backend && yarn run db:seed", "db:seed": "cd backend && yarn run db:seed",
"db:reset": "cd backend && yarn run db:reset", "db:reset": "cd backend && yarn run db:reset",
"docs:build": "NODE_OPTIONS=--openssl-legacy-provider vuepress build .",
"docs:dev": "NODE_OPTIONS=--openssl-legacy-provider vuepress dev .",
"cypress:run": "cypress run --e2e --browser electron --config-file ./cypress/cypress.config.js", "cypress:run": "cypress run --e2e --browser electron --config-file ./cypress/cypress.config.js",
"cypress:open": "cypress open --e2e --browser electron --config-file ./cypress/cypress.config.js", "cypress:open": "cypress open --e2e --browser electron --config-file ./cypress/cypress.config.js",
"cucumber:setup": "cd backend && yarn run dev",
"cucumber": "wait-on tcp:4000 && cucumber-js --require-module @babel/register --exit",
"release": "yarn version --no-git-tag-version --no-commit-hooks --no-commit && auto-changelog --latest-version $(node -p -e \"require('./package.json').version\") && cd backend && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../package.json').version\") && cd ../webapp && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../package.json').version\") && cd ../webapp/maintenance/source && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../../../package.json').version\")" "release": "yarn version --no-git-tag-version --no-commit-hooks --no-commit && auto-changelog --latest-version $(node -p -e \"require('./package.json').version\") && cd backend && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../package.json').version\") && cd ../webapp && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../package.json').version\") && cd ../webapp/maintenance/source && yarn version --no-git-tag-version --no-commit-hooks --no-commit --new-version $(node -p -e \"require('./../../../package.json').version\")"
}, },
"devDependencies": { "devDependencies": {
"@babel/core": "^7.23.3", "@babel/core": "^7.23.7",
"@babel/preset-env": "^7.23.3", "@babel/preset-env": "^7.23.9",
"@babel/register": "^7.22.15", "@babel/register": "^7.22.15",
"@badeball/cypress-cucumber-preprocessor": "^19.1.1", "@badeball/cypress-cucumber-preprocessor": "^20.0.1",
"@cypress/browserify-preprocessor": "^3.0.2", "@cypress/browserify-preprocessor": "^3.0.2",
"@faker-js/faker": "8.3.1", "@cucumber/cucumber": "10.3.1",
"@faker-js/faker": "8.4.0",
"auto-changelog": "^2.3.0", "auto-changelog": "^2.3.0",
"bcryptjs": "^2.4.3", "bcryptjs": "^2.4.3",
"cross-env": "^7.0.3", "cross-env": "^7.0.3",
"cucumber": "^6.0.5", "cypress": "^13.6.3",
"cypress": "^13.5.1",
"cypress-network-idle": "^1.14.2", "cypress-network-idle": "^1.14.2",
"date-fns": "^2.25.0", "date-fns": "^2.25.0",
"dotenv": "^16.3.1", "dotenv": "^16.3.1",
@ -53,13 +52,19 @@
"import": "^0.0.6", "import": "^0.0.6",
"jsonwebtoken": "^9.0.2", "jsonwebtoken": "^9.0.2",
"mock-socket": "^9.0.3", "mock-socket": "^9.0.3",
"multiple-cucumber-html-reporter": "^3.4.0", "multiple-cucumber-html-reporter": "^3.6.0",
"neo4j-driver": "^4.3.4", "neo4j-driver": "^4.3.4",
"neode": "^0.4.8", "neode": "^0.4.8",
"rosie": "^2.1.0", "rosie": "^2.1.0",
"slug": "^8.2.3", "slug": "^8.2.3",
"wait-on": "^7.2.0" "wait-on": "^7.2.0"
}, },
"optionalDependencies": {
"@vuepress/bundler-vite": "^2.0.0-rc.2",
"vuepress": "^2.0.0-rc.2",
"vuepress-plugin-search-pro": "^2.0.0-rc.15",
"vuepress-theme-hope": "^2.0.0-rc.15"
},
"resolutions": { "resolutions": {
"set-value": "^2.0.1", "set-value": "^2.0.1",
"nan": "2.17.0" "nan": "2.17.0"

View File

@ -25,6 +25,10 @@ module.exports = {
'no-console': ['error'], 'no-console': ['error'],
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off', 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'vue/component-name-in-template-casing': ['error', 'kebab-case'], 'vue/component-name-in-template-casing': ['error', 'kebab-case'],
// deactivate Vue3 rules for now, project will be migrated to Vue3
'vue/multi-word-component-names': 0,
'vue/no-mutating-props': 0,
'vue/no-v-text-v-html-on-component': 0,
'prettier/prettier': ['error', { 'prettier/prettier': ['error', {
htmlWhitespaceSensitivity: 'ignore' htmlWhitespaceSensitivity: 'ignore'
}], }],

View File

@ -59,8 +59,8 @@ We ensure the quality of our frontend code by using
For more information see our [frontend testing guide](testing.md). Use these commands to run the tests: For more information see our [frontend testing guide](testing.md). Use these commands to run the tests:
{% tabs %} ::: tabs
{% tab title="With Docker" %} @tab:active With Docker
After starting the application following the above guidelines, open new terminal windows for each of these commands: After starting the application following the above guidelines, open new terminal windows for each of these commands:
@ -81,9 +81,7 @@ $ docker-compose exec webapp yarn storybook
You can then visit the Storybook playground on `http://localhost:3002` You can then visit the Storybook playground on `http://localhost:3002`
{% endtab %} @tab title Without Docker
{% tab title="Without Docker" %}
After starting the application following the above guidelines, open new terminal windows and navigate to the `/webapp` directory for each of these commands: After starting the application following the above guidelines, open new terminal windows and navigate to the `/webapp` directory for each of these commands:
@ -109,8 +107,7 @@ $ yarn storybook
You can then visit the Storybook playground on `http://localhost:3002` You can then visit the Storybook playground on `http://localhost:3002`
{% endtab %} :::
{% endtabs %}
## Maintenance Mode ## Maintenance Mode

View File

@ -113,9 +113,9 @@ describe('AvatarMenu.vue', () => {
expect(settingsLink.exists()).toBe(true) expect(settingsLink.exists()).toBe(true)
}) })
it('displays a total of 4 links', () => { it('displays a total of 6 links', () => {
const allLinks = wrapper.findAll('.ds-menu-item') const allLinks = wrapper.findAll('.ds-menu-item')
expect(allLinks).toHaveLength(4) expect(allLinks).toHaveLength(6)
}) })
}) })
@ -139,9 +139,9 @@ describe('AvatarMenu.vue', () => {
expect(moderationLink.exists()).toBe(true) expect(moderationLink.exists()).toBe(true)
}) })
it('displays a total of 5 links', () => { it('displays a total of 7 links', () => {
const allLinks = wrapper.findAll('.ds-menu-item') const allLinks = wrapper.findAll('.ds-menu-item')
expect(allLinks).toHaveLength(5) expect(allLinks).toHaveLength(7)
}) })
}) })
@ -165,9 +165,9 @@ describe('AvatarMenu.vue', () => {
expect(adminLink.exists()).toBe(true) expect(adminLink.exists()).toBe(true)
}) })
it('displays a total of 6 links', () => { it('displays a total of 8 links', () => {
const allLinks = wrapper.findAll('.ds-menu-item') const allLinks = wrapper.findAll('.ds-menu-item')
expect(allLinks).toHaveLength(6) expect(allLinks).toHaveLength(8)
}) })
}) })
}) })

View File

@ -93,7 +93,17 @@ export default {
icon: 'users', icon: 'users',
}, },
{ {
name: this.$t('notifications.pageLink'), name: this.$t('header.avatarMenu.map'),
path: `/map`,
icon: 'globe',
},
{
name: this.$t('header.avatarMenu.chats'),
path: `/chat`,
icon: 'chat-bubble',
},
{
name: this.$t('header.avatarMenu.notifications'),
path: '/notifications', path: '/notifications',
icon: 'bell', icon: 'bell',
}, },

View File

@ -4,7 +4,7 @@
ghost ghost
circle circle
v-tooltip="{ v-tooltip="{
content: $t('header.chat.tooltip'), content: $t('header.chats.tooltip'),
placement: 'bottom-start', placement: 'bottom-start',
}" }"
> >

View File

@ -16,6 +16,7 @@
/> />
</slot> </slot>
</template> </template>
<!-- eslint-disable-next-line vue/no-useless-template-attributes -->
<template #popover="" class="legend"> <template #popover="" class="legend">
<div class="legend-container"> <div class="legend-container">
<div class="legend-header">{{ $t(`editor.legend.legendTitle`) }}</div> <div class="legend-header">{{ $t(`editor.legend.legendTitle`) }}</div>

View File

@ -17,6 +17,9 @@
<ds-text> <ds-text>
{{ $t('components.registration.email-nonce.form.description') }} {{ $t('components.registration.email-nonce.form.description') }}
</ds-text> </ds-text>
<ds-text>
{{ $t('components.registration.email-nonce.form.click-next') }}
</ds-text>
<base-button :disabled="disabled" filled name="submit" type="submit"> <base-button :disabled="disabled" filled name="submit" type="submit">
{{ $t('components.registration.email-nonce.form.next') }} {{ $t('components.registration.email-nonce.form.next') }}
</base-button> </base-button>

View File

@ -6,7 +6,7 @@
circle circle
ghost ghost
v-tooltip="{ v-tooltip="{
content: $t('group.button.tooltip'), content: $t('header.groups.tooltip'),
placement: 'bottom-start', placement: 'bottom-start',
}" }"
/> />

View File

@ -6,7 +6,7 @@
circle circle
ghost ghost
v-tooltip="{ v-tooltip="{
content: $t('map.button.tooltip'), content: $t('header.map.tooltip'),
placement: 'bottom-start', placement: 'bottom-start',
}" }"
> >

View File

@ -9,7 +9,7 @@
ghost ghost
circle circle
v-tooltip="{ v-tooltip="{
content: $t('notifications.headerMenuButton.tooltip'), content: $t('header.notifications.tooltip'),
placement: 'bottom-start', placement: 'bottom-start',
}" }"
/> />
@ -20,7 +20,7 @@
ghost ghost
circle circle
v-tooltip="{ v-tooltip="{
content: $t('notifications.headerMenuButton.tooltip'), content: $t('header.notifications.tooltip'),
placement: 'bottom-start', placement: 'bottom-start',
}" }"
@click="toggleMenu" @click="toggleMenu"

View File

@ -18,6 +18,9 @@
<ds-text> <ds-text>
{{ $t('components.registration.email-nonce.form.description') }} {{ $t('components.registration.email-nonce.form.description') }}
</ds-text> </ds-text>
<ds-text>
{{ $t('components.registration.email-nonce.form.click-next') }}
</ds-text>
<slot></slot> <slot></slot>
<ds-space margin="xxx-small" /> <ds-space margin="xxx-small" />
</ds-form> </ds-form>

View File

@ -1,5 +1,5 @@
// this file is duplicated in `backend/src/constants/group.js` and `webapp/constants/group.js` // this file is duplicated in `backend/src/constants/group.js` and `webapp/constants/group.js`
export const NAME_LENGTH_MIN = 3 export const NAME_LENGTH_MIN = 3
export const NAME_LENGTH_MAX = 50 export const NAME_LENGTH_MAX = 50
export const DESCRIPTION_WITHOUT_HTML_LENGTH_MIN = 50 // with removed HTML tags export const DESCRIPTION_WITHOUT_HTML_LENGTH_MIN = 3 // with removed HTML tags
export const SHOW_GROUP_BUTTON_IN_HEADER = true export const SHOW_GROUP_BUTTON_IN_HEADER = true

View File

@ -22,8 +22,7 @@ const ORGANIZATION = defaultPageParamsPages.ORGANIZATION.overwrite({
const DONATE = defaultPageParamsPages.DONATE.overwrite({ const DONATE = defaultPageParamsPages.DONATE.overwrite({
// if defined it's dominating // if defined it's dominating
externalLink: { externalLink: {
// we use 'ocelot-social.herokuapp.com' at the moment, because redirections of 'ocelot.social' subpages are not working correctly url: 'https://busfaktor.org/en/spenden',
url: 'https://ocelot-social.herokuapp.com/donations',
target: '_blank', target: '_blank',
}, },
@ -39,8 +38,7 @@ const DONATE = defaultPageParamsPages.DONATE.overwrite({
}) })
const IMPRINT = defaultPageParamsPages.IMPRINT.overwrite({ const IMPRINT = defaultPageParamsPages.IMPRINT.overwrite({
externalLink: { externalLink: {
// we use 'ocelot-social.herokuapp.com' at the moment, because redirections of 'ocelot.social' subpages are not working correctly url: 'http://ocelot.social/en/impressum',
url: 'https://ocelot-social.herokuapp.com/imprint',
target: '_blank', target: '_blank',
}, },

View File

@ -195,8 +195,9 @@
"yourEmail": "Deine E-Mail-Adresse:" "yourEmail": "Deine E-Mail-Adresse:"
}, },
"email-nonce": { "email-nonce": {
"buttonTitle": "Bestätigen", "buttonTitle": "Weiter",
"form": { "form": {
"click-next": "Click auf Weiter.",
"description": "Öffne Dein E-Mail Postfach und gib den Code ein, den wir geschickt haben.", "description": "Öffne Dein E-Mail Postfach und gib den Code ein, den wir geschickt haben.",
"next": "Weiter", "next": "Weiter",
"nonce": "E-Mail-Code: 32143", "nonce": "E-Mail-Code: 32143",
@ -480,9 +481,6 @@
"addUserNoOptions": "Keine Nutzer gefunden!", "addUserNoOptions": "Keine Nutzer gefunden!",
"addUserPlaceholder": "Nutzername", "addUserPlaceholder": "Nutzername",
"allGroups": "Alle Gruppen", "allGroups": "Alle Gruppen",
"button": {
"tooltip": "Gruppen anzeigen"
},
"categories": "Thema ::: Themen", "categories": "Thema ::: Themen",
"categoriesTitle": "Themen der Gruppe", "categoriesTitle": "Themen der Gruppe",
"changeMemberRole": "Die Rolle wurde auf „{role}“ geändert!", "changeMemberRole": "Die Rolle wurde auf „{role}“ geändert!",
@ -574,11 +572,23 @@
"button": { "button": {
"tooltip": "Mein Profil" "tooltip": "Mein Profil"
}, },
"chats": "Chats",
"groups": "Gruppen", "groups": "Gruppen",
"myProfile": "Mein Profil" "map": "Landkarte",
"myProfile": "Mein Profil",
"notifications": "Benachrichtigungen"
}, },
"chat": { "chats": {
"tooltip": "Meine Chats" "tooltip": "Chats"
},
"groups": {
"tooltip": "Gruppen"
},
"map": {
"tooltip": "Landkarte"
},
"notifications": {
"tooltip": "Banachrichtigungen"
} }
}, },
"index": { "index": {
@ -619,9 +629,6 @@
}, },
"map": { "map": {
"alertMessage": "Es kann nicht auf die Karte zugegriffen werden: Der Mapbox-Token ist auf dem Server nicht gesetzt!", "alertMessage": "Es kann nicht auf die Karte zugegriffen werden: Der Mapbox-Token ist auf dem Server nicht gesetzt!",
"button": {
"tooltip": "Landkarte anzeigen"
},
"legend": { "legend": {
"event": "Veranstaltung", "event": "Veranstaltung",
"group": "Gruppe", "group": "Gruppe",
@ -725,9 +732,6 @@
"unread": "Ungelesen" "unread": "Ungelesen"
}, },
"group": "Beschreibung", "group": "Beschreibung",
"headerMenuButton": {
"tooltip": "Meine Banachrichtigungen"
},
"markAllAsRead": "Markiere alle als gelesen", "markAllAsRead": "Markiere alle als gelesen",
"pageLink": "Alle Benachrichtigungen", "pageLink": "Alle Benachrichtigungen",
"post": "Beitrag oder Gruppe", "post": "Beitrag oder Gruppe",

View File

@ -195,9 +195,10 @@
"yourEmail": "Your e-mail address:" "yourEmail": "Your e-mail address:"
}, },
"email-nonce": { "email-nonce": {
"buttonTitle": "Confirm", "buttonTitle": "Continue",
"form": { "form": {
"description": "Open your inbox and enter the code that we've sent to you.", "click-next": "Click on Continue.",
"description": "Open your e-mail inbox and enter the code that we've sent to you.",
"next": "Continue", "next": "Continue",
"nonce": "E-mail code: 32143", "nonce": "E-mail code: 32143",
"validations": { "validations": {
@ -480,9 +481,6 @@
"addUserNoOptions": "No users found!", "addUserNoOptions": "No users found!",
"addUserPlaceholder": "User name", "addUserPlaceholder": "User name",
"allGroups": "All Groups", "allGroups": "All Groups",
"button": {
"tooltip": "Show groups"
},
"categories": "Topic ::: Topics", "categories": "Topic ::: Topics",
"categoriesTitle": "Topics of the group", "categoriesTitle": "Topics of the group",
"changeMemberRole": "The role has been changed to “{role}”!", "changeMemberRole": "The role has been changed to “{role}”!",
@ -574,11 +572,23 @@
"button": { "button": {
"tooltip": "My profile" "tooltip": "My profile"
}, },
"chats": "Chats",
"groups": "Groups", "groups": "Groups",
"myProfile": "My profile" "map": "Map",
"myProfile": "My profile",
"notifications": "Notifications"
}, },
"chat": { "chats": {
"tooltip": "My chats" "tooltip": "Chats"
},
"groups": {
"tooltip": "Groups"
},
"map": {
"tooltip": "Map"
},
"notifications": {
"tooltip": "Notifications"
} }
}, },
"index": { "index": {
@ -619,9 +629,6 @@
}, },
"map": { "map": {
"alertMessage": "The map cannot be accessed: The Mapbox token is not set on the server!", "alertMessage": "The map cannot be accessed: The Mapbox token is not set on the server!",
"button": {
"tooltip": "Show map"
},
"legend": { "legend": {
"event": "Event", "event": "Event",
"group": "Group", "group": "Group",
@ -725,9 +732,6 @@
"unread": "Unread" "unread": "Unread"
}, },
"group": "Description", "group": "Description",
"headerMenuButton": {
"tooltip": "My notifications"
},
"markAllAsRead": "Mark all as read", "markAllAsRead": "Mark all as read",
"pageLink": "All notifications", "pageLink": "All notifications",
"post": "Post or Group", "post": "Post or Group",

View File

@ -316,6 +316,26 @@
"hashtag-search": "Buscando a #{hashtag}", "hashtag-search": "Buscando a #{hashtag}",
"title": "Su burbuja de filtro" "title": "Su burbuja de filtro"
}, },
"header": {
"avatarMenu": {
"chats": "Chats",
"groups": "Grupos",
"map": "Mapa",
"notifications": "Notificaciones"
},
"chats": {
"tooltip": "Chats"
},
"groups": {
"tooltip": "Grupos"
},
"map": {
"tooltip": "Mapa"
},
"notifications": {
"tooltip": "Notificaciones"
}
},
"index": { "index": {
"change-filter-settings": "Cambie la configuración de sus filtros para obtener más resultados.", "change-filter-settings": "Cambie la configuración de sus filtros para obtener más resultados.",
"no-results": "No se han encontrado contribuciones." "no-results": "No se han encontrado contribuciones."

View File

@ -142,6 +142,7 @@
}, },
"email-nonce": { "email-nonce": {
"form": { "form": {
"click-next": "Cliquez sur Continuer.",
"description": "Ouvrez votre boîte de réception et entrez le code que nous vous avons envoyé.", "description": "Ouvrez votre boîte de réception et entrez le code que nous vous avons envoyé.",
"next": "Continuer", "next": "Continuer",
"nonce": "Entrez votre code", "nonce": "Entrez votre code",
@ -305,6 +306,26 @@
"hashtag-search": "Recherche de #{hashtag}", "hashtag-search": "Recherche de #{hashtag}",
"title": "Votre bulle de filtre" "title": "Votre bulle de filtre"
}, },
"header": {
"avatarMenu": {
"chats": "Chats",
"groups": "Groupes",
"map": "Carte",
"notifications": "Notifications"
},
"chats": {
"tooltip": "Chats"
},
"groups": {
"tooltip": "Groupes"
},
"map": {
"tooltip": "Carte"
},
"notifications": {
"tooltip": "Notifications"
}
},
"index": { "index": {
"change-filter-settings": "Modifiez les paramètres de filtrage pour obtenir plus de résultats.", "change-filter-settings": "Modifiez les paramètres de filtrage pour obtenir plus de résultats.",
"no-results": "Pas de contribution trouvée." "no-results": "Pas de contribution trouvée."
@ -406,9 +427,6 @@
"unread": "Non lu" "unread": "Non lu"
}, },
"group": "Description", "group": "Description",
"headerMenuButton": {
"tooltip": "Mes notifications"
},
"markAllAsRead": "Tout marquer comme lu", "markAllAsRead": "Tout marquer comme lu",
"pageLink": "Toutes les notifications", "pageLink": "Toutes les notifications",
"post": "Post", "post": "Post",

View File

@ -310,6 +310,22 @@
"hashtag-search": null, "hashtag-search": null,
"title": null "title": null
}, },
"header": {
"avatarMenu": {
"chats": "Chat",
"groups": "Gruppi",
"notifications": "Notifiche"
},
"chats": {
"tooltip": "Chat"
},
"groups": {
"tooltip": "Gruppi"
},
"notifications": {
"tooltip": "Notifiche"
}
},
"index": { "index": {
"change-filter-settings": null, "change-filter-settings": null,
"no-results": null "no-results": null
@ -356,7 +372,7 @@
"unread": null "unread": null
}, },
"markAllAsRead": "Segna tutti come letti", "markAllAsRead": "Segna tutti come letti",
"pageLink": null, "pageLink": "Tutte le notifiche",
"post": null, "post": null,
"reason": { "reason": {
"commented_on_post": null, "commented_on_post": null,

View File

@ -93,6 +93,22 @@
"membersCount": null, "membersCount": null,
"membersListTitle": null "membersListTitle": null
}, },
"header": {
"avatarMenu": {
"chats": "Chats",
"groups": "Groepen",
"notifications": "Notificaties"
},
"chats": {
"tooltip": "Chats"
},
"groups": {
"tooltip": "Groepen"
},
"notifications": {
"tooltip": "Notificaties"
}
},
"login": { "login": {
"email": "Uw E-mail", "email": "Uw E-mail",
"hello": "Hallo", "hello": "Hallo",
@ -111,7 +127,7 @@
"unread": null "unread": null
}, },
"markAllAsRead": "Markeer alles als gelezen", "markAllAsRead": "Markeer alles als gelezen",
"pageLink": null, "pageLink": "Alle notificaties",
"post": null, "post": null,
"reason": { "reason": {
"commented_on_post": null, "commented_on_post": null,

View File

@ -180,6 +180,22 @@
"hashtags-filter": { "hashtags-filter": {
"title": "Twoja bańka filtrująca" "title": "Twoja bańka filtrująca"
}, },
"header": {
"avatarMenu": {
"chats": "Czaty",
"groups": "Grupy",
"notifications": "Powiadomienia"
},
"chats": {
"tooltip": "Czaty"
},
"groups": {
"tooltip": "Grupy"
},
"notifications": {
"tooltip": "Powiadomienia"
}
},
"login": { "login": {
"email": "Twój adres e-mail", "email": "Twój adres e-mail",
"forgotPassword": "Zapomniałeś hasła?", "forgotPassword": "Zapomniałeś hasła?",
@ -203,7 +219,8 @@
"markAllAsRead": "Oznacz wszystkie jako przeczytane", "markAllAsRead": "Oznacz wszystkie jako przeczytane",
"menu": { "menu": {
"mentioned": "wspomiał o Tobie we wpisie" "mentioned": "wspomiał o Tobie we wpisie"
} },
"pageLink": "Wszystkie powiadomienia"
}, },
"post": { "post": {
"comment": { "comment": {

View File

@ -348,6 +348,22 @@
"hashtag-search": "Procurando por #{hashtag}", "hashtag-search": "Procurando por #{hashtag}",
"title": "Sua bolha de filtro" "title": "Sua bolha de filtro"
}, },
"header": {
"avatarMenu": {
"chats": "Chats",
"groups": "Grupos",
"notifications": "Notificações"
},
"chats": {
"tooltip": "Chats"
},
"groups": {
"tooltip": "Grupos"
},
"notifications": {
"tooltip": "Notificações"
}
},
"index": { "index": {
"change-filter-settings": "Altere suas configurações de filtro para obter mais resultados.", "change-filter-settings": "Altere suas configurações de filtro para obter mais resultados.",
"no-results": "Nenhuma contribuição encontrada." "no-results": "Nenhuma contribuição encontrada."

View File

@ -327,6 +327,22 @@
"hashtag-search": "Поиск по #{hashtag}", "hashtag-search": "Поиск по #{hashtag}",
"title": "Ваш фильтр пузыря" "title": "Ваш фильтр пузыря"
}, },
"header": {
"avatarMenu": {
"chats": "Чаты",
"groups": "Группы",
"notifications": "Уведомления"
},
"chats": {
"tooltip": "Чаты"
},
"groups": {
"tooltip": "Группы"
},
"notifications": {
"tooltip": "Уведомления"
}
},
"index": { "index": {
"change-filter-settings": "Измените настройки фильтра, чтобы получить больше результатов.", "change-filter-settings": "Измените настройки фильтра, чтобы получить больше результатов.",
"no-results": "Посты не найдены." "no-results": "Посты не найдены."

View File

@ -8,8 +8,8 @@ The maintenance mode shows a translatable page that tells the user that we are r
At the moment the maintenance mode can only be locally tested with Docker-Compose. At the moment the maintenance mode can only be locally tested with Docker-Compose.
{% tabs %} ::: tabs
{% tab title="Locally Without Docker" %} @tab:active Locally Without Docker
{% hint style="info" %} {% hint style="info" %}
TODO: Implement a locally running maintenance mode! Without Docker … TODO: Implement a locally running maintenance mode! Without Docker …
@ -25,8 +25,7 @@ $ yarn generate:maintenance
… is unfortunatelly **not(!)** working at the moment. … is unfortunatelly **not(!)** working at the moment.
This is because the code is rewritten to be easy usable for Docker-Compose. Therefore we lost this possibility. This is because the code is rewritten to be easy usable for Docker-Compose. Therefore we lost this possibility.
{% endtab %} @tab Locally With Docker
{% tab title="Locally With Docker" %}
To get the maintenance mode running use the command: To get the maintenance mode running use the command:
@ -37,3 +36,5 @@ $ docker-compose up
And the maintenance mode page or service will be started as well in an own container. And the maintenance mode page or service will be started as well in an own container.
In the browser you can reach it under `http://localhost:3001/`. In the browser you can reach it under `http://localhost:3001/`.
:::

View File

@ -21,7 +21,7 @@
}, },
"dependencies": { "dependencies": {
"@human-connection/styleguide": "0.5.22", "@human-connection/styleguide": "0.5.22",
"@mapbox/mapbox-gl-geocoder": "^5.0.1", "@mapbox/mapbox-gl-geocoder": "^5.0.2",
"@nuxtjs/apollo": "^4.0.0-rc19", "@nuxtjs/apollo": "^4.0.0-rc19",
"@nuxtjs/axios": "~5.9.7", "@nuxtjs/axios": "~5.9.7",
"@nuxtjs/dotenv": "~1.4.1", "@nuxtjs/dotenv": "~1.4.1",
@ -39,7 +39,7 @@
"graphql": "~14.7.0", "graphql": "~14.7.0",
"intersection-observer": "^0.12.0", "intersection-observer": "^0.12.0",
"jsonwebtoken": "~9.0.0", "jsonwebtoken": "~9.0.0",
"linkify-it": "~3.0.2", "linkify-it": "~5.0.0",
"mapbox-gl": "1.13.2", "mapbox-gl": "1.13.2",
"node-fetch": "^2.6.1", "node-fetch": "^2.6.1",
"nuxt": "~2.12.1", "nuxt": "~2.12.1",
@ -54,7 +54,7 @@
"v-mapbox": "^1.11.2", "v-mapbox": "^1.11.2",
"v-tooltip": "~2.1.3", "v-tooltip": "~2.1.3",
"validator": "^13.0.0", "validator": "^13.0.0",
"vue-advanced-chat": "^2.0.7", "vue-advanced-chat": "^2.0.10",
"vue-count-to": "~1.0.13", "vue-count-to": "~1.0.13",
"vue-infinite-loading": "^2.4.5", "vue-infinite-loading": "^2.4.5",
"vue-izitoast": "^1.2.1", "vue-izitoast": "^1.2.1",
@ -67,7 +67,7 @@
"zxcvbn": "^4.4.2" "zxcvbn": "^4.4.2"
}, },
"devDependencies": { "devDependencies": {
"@babel/core": "~7.22.1", "@babel/core": "^7.23.7",
"@babel/plugin-syntax-dynamic-import": "^7.8.3", "@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/preset-env": "^7.22.4", "@babel/preset-env": "^7.22.4",
"@faker-js/faker": "5.1.0", "@faker-js/faker": "5.1.0",
@ -100,11 +100,11 @@
"eslint-plugin-prettier": "~3.4.0", "eslint-plugin-prettier": "~3.4.0",
"eslint-plugin-promise": "~4.3.1", "eslint-plugin-promise": "~4.3.1",
"eslint-plugin-standard": "~5.0.0", "eslint-plugin-standard": "~5.0.0",
"eslint-plugin-vue": "~6.2.2", "eslint-plugin-vue": "~9.19.2",
"flush-promises": "^1.0.2", "flush-promises": "^1.0.2",
"identity-obj-proxy": "^3.0.0", "identity-obj-proxy": "^3.0.0",
"jest": "29.5", "jest": "29.5",
"jest-environment-jsdom": "^29.4.2", "jest-environment-jsdom": "^29.7.0",
"mutation-observer": "^1.0.3", "mutation-observer": "^1.0.3",
"prettier": "~2.7.1", "prettier": "~2.7.1",
"sass-loader": "~10.1.1", "sass-loader": "~10.1.1",

View File

@ -57,6 +57,7 @@
</div> </div>
</template> </template>
<!-- eslint-disable vue/no-reserved-component-names -->
<script> <script>
import { isEmpty, toArray } from 'lodash' import { isEmpty, toArray } from 'lodash'
import mapboxgl from 'mapbox-gl' import mapboxgl from 'mapbox-gl'
@ -560,6 +561,7 @@ export default {
}, },
} }
</script> </script>
<!-- eslint-enable vue/no-reserved-component-names -->
<style lang="scss"> <style lang="scss">
// description: https: //github.com/geospoc/v-mapbox/tree/v1.11.2/docs // description: https: //github.com/geospoc/v-mapbox/tree/v1.11.2/docs

File diff suppressed because it is too large Load Diff

3275
yarn.lock

File diff suppressed because it is too large Load Diff