✨ Added pre-commit
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
[flake8]
|
||||
max-line-length = 120
|
||||
extend-ignore = E203
|
||||
extend-ignore = E203
|
||||
|
||||
+1
-1
@@ -1,2 +1,2 @@
|
||||
ko_fi: mawoka
|
||||
liberapay: Mawoka
|
||||
liberapay: Mawoka
|
||||
|
||||
@@ -30,7 +30,7 @@ If applicable, add the error stacktrace to help explain your problem.
|
||||
- Browser [e.g. Chrome, Firefox, Safari]:
|
||||
- ~~Classquiz Version [e.g. 0.10]:~~ :warning:** No versioning for now** :warning:
|
||||
- Classquiz installation [e.g. classquiz.de]:
|
||||
- Commit SHA [e.g : ed35c5c69019e7cd6331ea438519f53b8bce70cf]:
|
||||
- Commit SHA [e.g : ed35c5c69019e7cd6331ea438519f53b8bce70cf]:
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
|
||||
@@ -15,4 +15,3 @@ If applicable, add screenshots to help explain your feature.
|
||||
Add any other context about the problem here.
|
||||
|
||||
Thanks for contributing to ClassQuiz!
|
||||
|
||||
|
||||
@@ -12,4 +12,3 @@ A clear and concise description of the improvement you're asking for.
|
||||
Add any other context about the problem here.
|
||||
|
||||
Thanks for contributing to ClassQuiz!
|
||||
|
||||
|
||||
@@ -32,4 +32,4 @@ jobs:
|
||||
- name: Lint
|
||||
working-directory: ./frontend
|
||||
run: |
|
||||
pnpm run lint
|
||||
pnpm run lint
|
||||
|
||||
@@ -37,7 +37,7 @@ jobs:
|
||||
run: |
|
||||
# Install deepsource CLI
|
||||
curl https://deepsource.io/cli | sh
|
||||
|
||||
|
||||
# From the root directory, run the report coverage command
|
||||
./bin/deepsource report --analyzer test-coverage --key python --value-file ./coverage.xml
|
||||
|
||||
|
||||
+1
-1
@@ -6,4 +6,4 @@ node_modules/
|
||||
*.db
|
||||
*.rdb
|
||||
survey.json
|
||||
.coverage
|
||||
.coverage
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
# See https://pre-commit.com for more information
|
||||
# See https://pre-commit.com/hooks.html for more hooks
|
||||
repos:
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
rev: v4.3.0
|
||||
hooks:
|
||||
- id: trailing-whitespace
|
||||
- id: end-of-file-fixer
|
||||
- id: check-yaml
|
||||
- id: check-added-large-files
|
||||
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 22.3.0
|
||||
hooks:
|
||||
- id: black
|
||||
- repo: https://github.com/pre-commit/mirrors-prettier
|
||||
rev: 'v2.6.2' # Use the sha / tag you want to point at
|
||||
hooks:
|
||||
- id: prettier
|
||||
files: "^frontend/"
|
||||
exclude: "^frontend/src/lib/i18n/locales/"
|
||||
additional_dependencies:
|
||||
- "prettier-plugin-svelte@latest"
|
||||
- "prettier@latest"
|
||||
+1
-1
@@ -22,4 +22,4 @@ an issue here on GitHub.
|
||||
|
||||
Go to [Weblate](https://translate.mawoka.eu/projects/classquiz/frontend/).
|
||||
If the language isn't available, please open
|
||||
an issue here, so I'll be able to add it.
|
||||
an issue here, so I'll be able to add it.
|
||||
|
||||
+1
-1
@@ -12,4 +12,4 @@ EXPOSE 80
|
||||
ENV PYTHONPATH=/app
|
||||
RUN chmod +x start.sh
|
||||
ENV APP_MODULE=classquiz:app
|
||||
CMD ["./start.sh"]
|
||||
CMD ["./start.sh"]
|
||||
|
||||
@@ -36,6 +36,7 @@ flake8 = "*"
|
||||
black = "*"
|
||||
pytest-dependency = "*"
|
||||
pytest-order = "*"
|
||||
pre-commit = "*"
|
||||
|
||||
[requires]
|
||||
python_version = "3.10"
|
||||
|
||||
Generated
+116
-8
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"_meta": {
|
||||
"hash": {
|
||||
"sha256": "546fc11840f6375e7138824e7251b452fcb56e9bd736591360b6a831c2319634"
|
||||
"sha256": "7d4797eb27534a4d9abc7ae6cb3033255b792e22a0d67204153ab7cb0b2f5715"
|
||||
},
|
||||
"pipfile-spec": 6,
|
||||
"requires": {
|
||||
@@ -308,7 +308,7 @@
|
||||
"sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597",
|
||||
"sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df"
|
||||
],
|
||||
"markers": "python_version >= '3.5'",
|
||||
"markers": "python_full_version >= '3.5.0'",
|
||||
"version": "==2.0.12"
|
||||
},
|
||||
"click": {
|
||||
@@ -340,7 +340,7 @@
|
||||
"sha256:0f7569a4a6ff151958b64304071d370daa3243d15941a7beedf0c9fe5105603e",
|
||||
"sha256:a851e51367fb93e9e1361732c1d60dab63eff98712e503ea7d92e6eccb109b4f"
|
||||
],
|
||||
"markers": "python_version >= '3.6' and python_version < '4'",
|
||||
"markers": "python_version >= '3.6' and python_full_version < '4.0.0'",
|
||||
"version": "==2.2.1"
|
||||
},
|
||||
"ecdsa": {
|
||||
@@ -553,7 +553,7 @@
|
||||
"sha256:84d9dd047ffa80596e0f246e2eab0b391788b0503584e8945f2368256d2735ff",
|
||||
"sha256:9d643ff0a55b762d5cdb124b8eaa99c66322e2157b69160bc32796e824360e6d"
|
||||
],
|
||||
"markers": "python_version >= '3.5'",
|
||||
"markers": "python_full_version >= '3.5.0'",
|
||||
"version": "==3.3"
|
||||
},
|
||||
"jinja2": {
|
||||
@@ -994,7 +994,7 @@
|
||||
"sha256:bc7861137fbce630f17b03d3ad02ad0bf978c844f3536d0edda6499dafce2b6f",
|
||||
"sha256:d568723a7ebd25875d8d1eaf5dfa068cd2fc8194b2e483d7b1f7c81918dbec6b"
|
||||
],
|
||||
"markers": "python_version >= '3.7' and python_version < '4'",
|
||||
"markers": "python_version >= '3.7' and python_full_version < '4.0.0'",
|
||||
"version": "==2.28.0"
|
||||
},
|
||||
"rsa": {
|
||||
@@ -1002,7 +1002,7 @@
|
||||
"sha256:5c6bd9dc7a543b7fe4304a631f8a8a3b674e2bbfc49c2ae96200cdbe55df6b17",
|
||||
"sha256:95c5d300c4e879ee69708c428ba566c59478fd653cc3a22243eeb8ed846950bb"
|
||||
],
|
||||
"markers": "python_version >= '3.6' and python_version < '4'",
|
||||
"markers": "python_version >= '3.6' and python_full_version < '4.0.0'",
|
||||
"version": "==4.8"
|
||||
},
|
||||
"sentry-sdk": {
|
||||
@@ -1034,7 +1034,7 @@
|
||||
"sha256:471b71698eac1c2112a40ce2752bb2f4a4814c22a54a3eed3676bc0f5ca9f663",
|
||||
"sha256:c4666eecec1d3f50960c6bdf61ab7bc350648da6c126e3cf6898d8cd4ddcd3de"
|
||||
],
|
||||
"markers": "python_version >= '3.5'",
|
||||
"markers": "python_full_version >= '3.5.0'",
|
||||
"version": "==1.2.0"
|
||||
},
|
||||
"sqlalchemy": {
|
||||
@@ -1100,7 +1100,7 @@
|
||||
"sha256:44ece4d53fb1706f667c9bd1c648f5469a2ec925fcf3a776667042d645472c14",
|
||||
"sha256:aabaf16477806a5e1dd19aa41f8c2b7950dd3c746362d7e3223dbe6de6ac448e"
|
||||
],
|
||||
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' and python_version < '4'",
|
||||
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4' and python_full_version < '4.0.0'",
|
||||
"version": "==1.26.9"
|
||||
},
|
||||
"uvicorn": {
|
||||
@@ -1397,6 +1397,14 @@
|
||||
"index": "pypi",
|
||||
"version": "==22.3.0"
|
||||
},
|
||||
"cfgv": {
|
||||
"hashes": [
|
||||
"sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426",
|
||||
"sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"
|
||||
],
|
||||
"markers": "python_full_version >= '3.6.1'",
|
||||
"version": "==3.3.1"
|
||||
},
|
||||
"click": {
|
||||
"hashes": [
|
||||
"sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e",
|
||||
@@ -1452,6 +1460,21 @@
|
||||
"index": "pypi",
|
||||
"version": "==6.4.1"
|
||||
},
|
||||
"distlib": {
|
||||
"hashes": [
|
||||
"sha256:6564fe0a8f51e734df6333d08b8b94d4ea8ee6b99b5ed50613f731fd4089f34b",
|
||||
"sha256:e4b58818180336dc9c529bfb9a0b58728ffc09ad92027a3f30b7cd91e3458579"
|
||||
],
|
||||
"version": "==0.3.4"
|
||||
},
|
||||
"filelock": {
|
||||
"hashes": [
|
||||
"sha256:37def7b658813cda163b56fc564cdc75e86d338246458c4c28ae84cabefa2404",
|
||||
"sha256:3a0fd85166ad9dbab54c9aec96737b744106dc5f15c0b09a6744a445299fcf04"
|
||||
],
|
||||
"markers": "python_version >= '3.7'",
|
||||
"version": "==3.7.1"
|
||||
},
|
||||
"flake8": {
|
||||
"hashes": [
|
||||
"sha256:479b1304f72536a55948cb40a32dce8bb0ffe3501e26eaf292c7e60eb5e0428d",
|
||||
@@ -1460,6 +1483,14 @@
|
||||
"index": "pypi",
|
||||
"version": "==4.0.1"
|
||||
},
|
||||
"identify": {
|
||||
"hashes": [
|
||||
"sha256:0dca2ea3e4381c435ef9c33ba100a78a9b40c0bab11189c7cf121f75815efeaa",
|
||||
"sha256:3d11b16f3fe19f52039fb7e39c9c884b21cb1b586988114fbe42671f03de3e82"
|
||||
],
|
||||
"markers": "python_version >= '3.7'",
|
||||
"version": "==2.5.1"
|
||||
},
|
||||
"iniconfig": {
|
||||
"hashes": [
|
||||
"sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3",
|
||||
@@ -1481,6 +1512,13 @@
|
||||
],
|
||||
"version": "==0.4.3"
|
||||
},
|
||||
"nodeenv": {
|
||||
"hashes": [
|
||||
"sha256:3ef13ff90291ba2a4a7a4ff9a979b63ffdd00a464dbe04acf0ea6471517a4c2b",
|
||||
"sha256:621e6b7076565ddcacd2db0294c0381e01fd28945ab36bcf00f41c5daf63bef7"
|
||||
],
|
||||
"version": "==1.6.0"
|
||||
},
|
||||
"packaging": {
|
||||
"hashes": [
|
||||
"sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb",
|
||||
@@ -1512,6 +1550,14 @@
|
||||
"markers": "python_version >= '3.6'",
|
||||
"version": "==1.0.0"
|
||||
},
|
||||
"pre-commit": {
|
||||
"hashes": [
|
||||
"sha256:10c62741aa5704faea2ad69cb550ca78082efe5697d6f04e5710c3c229afdd10",
|
||||
"sha256:4233a1e38621c87d9dda9808c6606d7e7ba0e087cd56d3fe03202a01d2919615"
|
||||
],
|
||||
"index": "pypi",
|
||||
"version": "==2.19.0"
|
||||
},
|
||||
"py": {
|
||||
"hashes": [
|
||||
"sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719",
|
||||
@@ -1576,6 +1622,60 @@
|
||||
"index": "pypi",
|
||||
"version": "==1.0.1"
|
||||
},
|
||||
"pyyaml": {
|
||||
"hashes": [
|
||||
"sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293",
|
||||
"sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b",
|
||||
"sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57",
|
||||
"sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b",
|
||||
"sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4",
|
||||
"sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07",
|
||||
"sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba",
|
||||
"sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9",
|
||||
"sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287",
|
||||
"sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513",
|
||||
"sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0",
|
||||
"sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0",
|
||||
"sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92",
|
||||
"sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f",
|
||||
"sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2",
|
||||
"sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc",
|
||||
"sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c",
|
||||
"sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86",
|
||||
"sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4",
|
||||
"sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c",
|
||||
"sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34",
|
||||
"sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b",
|
||||
"sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c",
|
||||
"sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb",
|
||||
"sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737",
|
||||
"sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3",
|
||||
"sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d",
|
||||
"sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53",
|
||||
"sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78",
|
||||
"sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803",
|
||||
"sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a",
|
||||
"sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174",
|
||||
"sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"
|
||||
],
|
||||
"version": "==6.0"
|
||||
},
|
||||
"six": {
|
||||
"hashes": [
|
||||
"sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926",
|
||||
"sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"
|
||||
],
|
||||
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'",
|
||||
"version": "==1.16.0"
|
||||
},
|
||||
"toml": {
|
||||
"hashes": [
|
||||
"sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b",
|
||||
"sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"
|
||||
],
|
||||
"markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'",
|
||||
"version": "==0.10.2"
|
||||
},
|
||||
"tomli": {
|
||||
"hashes": [
|
||||
"sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc",
|
||||
@@ -1583,6 +1683,14 @@
|
||||
],
|
||||
"markers": "python_version >= '3.7'",
|
||||
"version": "==2.0.1"
|
||||
},
|
||||
"virtualenv": {
|
||||
"hashes": [
|
||||
"sha256:e617f16e25b42eb4f6e74096b9c9e37713cf10bf30168fb4a739f3fa8f898a3a",
|
||||
"sha256:ef589a79795589aada0c1c5b319486797c03b67ac3984c48c669c0e4f50df3a5"
|
||||
],
|
||||
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'",
|
||||
"version": "==20.14.1"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -76,4 +76,4 @@ return (example):
|
||||
"game_pin": "45823169",
|
||||
"started": false
|
||||
}
|
||||
```
|
||||
```
|
||||
|
||||
@@ -21,4 +21,4 @@
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -70,4 +70,4 @@
|
||||
</div>
|
||||
{% include 'footer.jinja2' %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -70,4 +70,4 @@
|
||||
</div>
|
||||
{% include 'footer.jinja2' %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -37,4 +37,4 @@ run(main())
|
||||
## Import-Quiz
|
||||
This script is meant just to be used with classquiz, not alone.
|
||||
---
|
||||
*Kahoot! and the K! logo are trademarks of Kahoot! AS*
|
||||
*Kahoot! and the K! logo are trademarks of Kahoot! AS*
|
||||
|
||||
+1
-1
@@ -69,4 +69,4 @@ services:
|
||||
- meilisearch-data:/data.ms
|
||||
volumes:
|
||||
data:
|
||||
meilisearch-data:
|
||||
meilisearch-data:
|
||||
|
||||
+1
-1
@@ -41,4 +41,4 @@ COPY --from=builder /usr/src/app/node_modules ./node_modules
|
||||
EXPOSE 3000
|
||||
|
||||
# the command that starts our app
|
||||
CMD ["pnpm", "run", "run:prod"]
|
||||
CMD ["pnpm", "run", "run:prod"]
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<script lang='ts'>
|
||||
<script lang="ts">
|
||||
import { onMount } from 'svelte';
|
||||
import '$lib/hljs.css';
|
||||
|
||||
@@ -11,12 +11,12 @@
|
||||
<svelte:head>
|
||||
<title>ClassQuiz/docs - Self-Host</title>
|
||||
<meta
|
||||
name='description'
|
||||
content='How to self-host ClassQuiz, the open-source quiz-application'
|
||||
name="description"
|
||||
content="How to self-host ClassQuiz, the open-source quiz-application"
|
||||
/>
|
||||
</svelte:head>
|
||||
<article
|
||||
class='prose prose-sm sm:prose lg:prose-lg xl:prose-xl mx-auto mt-10 prose-slate px-4 dark:prose-invert'
|
||||
class="prose prose-sm sm:prose lg:prose-lg xl:prose-xl mx-auto mt-10 prose-slate px-4 dark:prose-invert"
|
||||
>
|
||||
<h1>Self-Hosting</h1>
|
||||
<p>Since ClassQuiz is open-source, it can also be self-hosted.</p>
|
||||
@@ -30,35 +30,35 @@
|
||||
<h2>Requirements</h2>
|
||||
<h3>Software</h3>
|
||||
<ul>
|
||||
<li><a href='https://docker.com'>Docker</a></li>
|
||||
<li><a href='https://git-scm.com/'>Git</a></li>
|
||||
<li><a href="https://docker.com">Docker</a></li>
|
||||
<li><a href="https://git-scm.com/">Git</a></li>
|
||||
<li>
|
||||
A <a href='https://redis.com'>Redis</a>-Server
|
||||
A <a href="https://redis.com">Redis</a>-Server
|
||||
</li>
|
||||
</ul>
|
||||
<h3>3rd-Parties</h3>
|
||||
<h4>Required</h4>
|
||||
<ul>
|
||||
<li><a href='https://hcaptcha.com'>hCaptcha (Captcha)</a></li>
|
||||
<li><a href='https://www.mapbox.com/'>Mapbox (Maps)</a></li>
|
||||
<li><a href="https://hcaptcha.com">hCaptcha (Captcha)</a></li>
|
||||
<li><a href="https://www.mapbox.com/">Mapbox (Maps)</a></li>
|
||||
</ul>
|
||||
<h4>Optional</h4>
|
||||
<ul>
|
||||
<li><a href='https://sentry.io'>Sentry (Error-Logging)</a></li>
|
||||
<li><a href="https://sentry.io">Sentry (Error-Logging)</a></li>
|
||||
</ul>
|
||||
|
||||
<h2>Installation</h2>
|
||||
<p>At first, clone the repo:</p>
|
||||
|
||||
<pre><code class='language-bash'
|
||||
>git clone https://github.com/mawoka-myblock/classquiz && cd ClassQuiz</code
|
||||
></pre>
|
||||
<pre><code class="language-bash"
|
||||
>git clone https://github.com/mawoka-myblock/classquiz && cd ClassQuiz</code
|
||||
></pre>
|
||||
<p>
|
||||
Now, set a <b>VALID</b> Redis-URI in <code>frontend/Dockerfile</code> and, if you want Sentry,
|
||||
set a valid Sentry-DSN. Note: The problem is that the frontend-container tries to connect to Redis during the
|
||||
build-process. For that, you'll need to provide an available Redis-Instance. For that, I would recommend
|
||||
Upstash, because you get a free Redis-Instance which is available over the internet. This instance won't be used
|
||||
at runtime.
|
||||
set a valid Sentry-DSN. Note: The problem is that the frontend-container tries to connect to
|
||||
Redis during the build-process. For that, you'll need to provide an available Redis-Instance.
|
||||
For that, I would recommend Upstash, because you get a free Redis-Instance which is available
|
||||
over the internet. This instance won't be used at runtime.
|
||||
</p>
|
||||
<p>
|
||||
You must set a valid hCaptcha-Sitekey in the <code>frontend/Dockerfile</code>.
|
||||
@@ -77,11 +77,10 @@
|
||||
<h3>Storage Provider</h3>
|
||||
<p>
|
||||
You'll have to set up a storage provider for some pictures (these getting imported from
|
||||
KAHOOT!). For now, you can use <a href='https://deta.sh'>Deta</a> or the local filesystem.
|
||||
Please note that I would <b>NOT</b> use the local file system because of <a
|
||||
href='https://wiki.owasp.org/index.php/Path_Traversal'>Path Traversals</a>. I tried to prevent these attacks,
|
||||
but I really wouldn't trust it. You'll have
|
||||
to set the
|
||||
KAHOOT!). For now, you can use <a href="https://deta.sh">Deta</a> or the local filesystem.
|
||||
Please note that I would <b>NOT</b> use the local file system because of
|
||||
<a href="https://wiki.owasp.org/index.php/Path_Traversal">Path Traversals</a>. I tried to
|
||||
prevent these attacks, but I really wouldn't trust it. You'll have to set the
|
||||
<code>STORAGE_BACKEND</code>-environment-variable to either <code>deta</code> or
|
||||
<code>local</code>.
|
||||
</p>
|
||||
@@ -99,8 +98,8 @@
|
||||
Before you can start your stack, you have to set some environment-variables in your
|
||||
<code>docker-compose.yml</code>.
|
||||
</p>
|
||||
<pre><code class='language-yaml'
|
||||
>version: "3"
|
||||
<pre><code class="language-yaml"
|
||||
>version: "3"
|
||||
|
||||
services:
|
||||
frontend:
|
||||
@@ -184,7 +183,10 @@ volumes:
|
||||
data:
|
||||
meilisearch-data:
|
||||
</code></pre>
|
||||
<p>Run the following command to generate and set the secret up automatically</p><pre><code class='language-bash'>sed -i "s/TOP_SECRET/$(openssl rand -hex 32)/g" docker-compose.yml</code></pre>
|
||||
<p>Run the following command to generate and set the secret up automatically</p>
|
||||
<pre><code class="language-bash"
|
||||
>sed -i "s/TOP_SECRET/$(openssl rand -hex 32)/g" docker-compose.yml</code
|
||||
></pre>
|
||||
<p>Now build and deploy:</p>
|
||||
<pre><code>docker compose build && docker compose up -d</code></pre>
|
||||
<p>You'll have to create an index in Meilisearch with the following command:</p>
|
||||
|
||||
@@ -1 +1 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="1440" height="1440" preserveAspectRatio="xMidYMid meet" version="1.0" viewBox="0 0 1080 1080"><metadata>Created by potrace 1.14, written by Peter Selinger 2001-2017</metadata><g fill="#000" stroke="none"><path d="M5128 10795 c-1 -1 -43 -5 -93 -9 -152 -9 -225 -17 -370 -37 -181 -26 -182 -26 -300 -50 -55 -12 -111 -23 -125 -26 -42 -7 -261 -63 -335 -85 -38 -11 -72 -20 -75 -20 -14 -1 -325 -110 -395 -139 -11 -5 -60 -24 -108 -44 -97 -39 -309 -138 -397 -185 -30 -16 -80 -42 -110 -57 -30 -15 -56 -31 -58 -35 -2 -5 -8 -8 -12 -8 -37 0 -603 -378 -696 -464 -7 -6 -27 -22 -44 -36 -18 -14 -40 -32 -49 -40 -9 -8 -44 -37 -76 -65 -212 -176 -512 -488 -694 -720 -39 -49 -75 -95 -80 -101 -5 -6 -36 -49 -70 -95 -33 -46 -65 -89 -71 -96 -5 -7 -10 -16 -10 -22 0 -5 -4 -11 -8 -13 -8 -3 -72 -95 -72 -104 0 -3 -5 -10 -10 -17 -22 -25 -90 -137 -90 -147 0 -5 -4 -10 -10 -10 -5 0 -10 -4 -10 -10 0 -5 -13 -31 -28 -57 -109 -185 -236 -444 -322 -658 -18 -44 -36 -89 -41 -100 -11 -26 -79 -215 -85 -235 -2 -8 -18 -60 -35 -115 -28 -91 -67 -228 -74 -265 -2 -8 -8 -35 -15 -60 -13 -48 -18 -70 -26 -110 -3 -14 -7 -32 -9 -40 -3 -8 -7 -33 -10 -55 -4 -22 -10 -56 -15 -75 -5 -19 -11 -57 -15 -84 -3 -27 -8 -52 -9 -55 -2 -3 -7 -37 -11 -76 -4 -38 -8 -72 -10 -75 -2 -3 -6 -37 -10 -75 -4 -39 -8 -83 -10 -100 -27 -234 -27 -786 -1 -1030 2 -16 7 -61 11 -100 3 -38 8 -77 10 -85 2 -8 7 -39 10 -69 4 -30 9 -63 11 -75 2 -12 9 -48 14 -81 9 -52 53 -270 64 -315 2 -8 14 -53 26 -100 12 -47 23 -89 24 -95 21 -91 136 -430 201 -590 66 -163 229 -501 305 -630 29 -49 60 -104 71 -122 38 -67 197 -312 209 -323 3 -3 30 -39 60 -80 29 -41 56 -77 60 -80 4 -3 11 -12 16 -21 16 -30 164 -208 267 -324 88 -98 308 -318 402 -402 107 -95 113 -100 215 -182 52 -42 97 -79 98 -83 2 -5 10 -8 18 -8 8 0 14 -4 14 -8 0 -4 32 -30 71 -57 39 -28 84 -60 99 -72 15 -13 32 -23 38 -23 6 0 12 -3 14 -8 2 -4 35 -27 73 -52 39 -24 72 -47 75 -50 5 -6 130 -80 265 -157 65 -38 234 -126 245 -129 3 0 46 -20 95 -43 140 -66 185 -86 260 -116 39 -15 84 -33 100 -40 54 -23 388 -133 470 -155 95 -26 260 -67 295 -74 124 -25 232 -46 265 -50 23 -4 52 -9 65 -11 14 -3 41 -8 60 -10 19 -3 49 -7 65 -10 29 -4 93 -11 180 -20 278 -28 793 -28 1050 0 345 38 755 118 1002 196 212 67 291 93 318 104 17 7 66 27 110 43 268 101 595 263 869 430 33 20 66 40 71 45 6 4 55 37 110 74 122 80 362 259 391 290 12 13 24 23 28 23 7 0 15 6 64 50 15 14 59 52 97 85 88 77 363 352 436 435 165 190 319 383 319 400 0 5 4 10 8 10 4 0 16 13 25 30 10 16 23 35 30 42 14 15 180 266 190 288 4 8 16 29 26 45 219 353 404 775 556 1265 12 39 51 188 60 230 2 8 13 53 24 100 20 84 64 329 77 425 3 28 7 57 9 65 2 8 6 47 10 85 4 39 8 81 10 93 20 127 28 733 12 897 -5 44 -10 105 -13 135 -3 30 -7 71 -9 90 -3 19 -7 58 -10 85 -3 28 -8 61 -10 75 -2 14 -7 45 -10 70 -4 25 -16 92 -27 150 -11 58 -22 116 -24 130 -3 14 -10 43 -16 65 -11 42 -16 64 -24 105 -24 119 -143 492 -217 680 -101 256 -260 581 -382 781 -5 10 -23 40 -40 68 -16 28 -33 51 -37 51 -5 0 -8 5 -8 12 0 19 -217 332 -290 418 -8 10 -22 28 -30 40 -17 25 -46 60 -144 174 -178 208 -455 481 -641 631 -20 17 -42 35 -49 40 -6 6 -40 33 -76 60 -36 28 -67 52 -70 55 -3 3 -21 17 -40 30 -19 14 -39 28 -45 32 -31 25 -172 121 -250 171 -49 31 -95 60 -101 64 -12 9 -41 26 -103 60 -25 14 -50 29 -56 33 -67 49 -471 242 -672 321 -13 5 -33 13 -45 19 -13 5 -50 19 -83 30 -33 12 -69 25 -80 30 -57 25 -298 95 -477 140 -190 47 -477 101 -613 116 -33 3 -62 8 -65 9 -3 2 -48 6 -100 10 -52 4 -108 9 -125 12 -34 5 -661 13 -667 8z" transform="translate(0.000000,1080.000000) scale(0.100000,-0.100000)"/></g></svg>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="1440" height="1440" preserveAspectRatio="xMidYMid meet" version="1.0" viewBox="0 0 1080 1080"><metadata>Created by potrace 1.14, written by Peter Selinger 2001-2017</metadata><g fill="#000" stroke="none"><path d="M5128 10795 c-1 -1 -43 -5 -93 -9 -152 -9 -225 -17 -370 -37 -181 -26 -182 -26 -300 -50 -55 -12 -111 -23 -125 -26 -42 -7 -261 -63 -335 -85 -38 -11 -72 -20 -75 -20 -14 -1 -325 -110 -395 -139 -11 -5 -60 -24 -108 -44 -97 -39 -309 -138 -397 -185 -30 -16 -80 -42 -110 -57 -30 -15 -56 -31 -58 -35 -2 -5 -8 -8 -12 -8 -37 0 -603 -378 -696 -464 -7 -6 -27 -22 -44 -36 -18 -14 -40 -32 -49 -40 -9 -8 -44 -37 -76 -65 -212 -176 -512 -488 -694 -720 -39 -49 -75 -95 -80 -101 -5 -6 -36 -49 -70 -95 -33 -46 -65 -89 -71 -96 -5 -7 -10 -16 -10 -22 0 -5 -4 -11 -8 -13 -8 -3 -72 -95 -72 -104 0 -3 -5 -10 -10 -17 -22 -25 -90 -137 -90 -147 0 -5 -4 -10 -10 -10 -5 0 -10 -4 -10 -10 0 -5 -13 -31 -28 -57 -109 -185 -236 -444 -322 -658 -18 -44 -36 -89 -41 -100 -11 -26 -79 -215 -85 -235 -2 -8 -18 -60 -35 -115 -28 -91 -67 -228 -74 -265 -2 -8 -8 -35 -15 -60 -13 -48 -18 -70 -26 -110 -3 -14 -7 -32 -9 -40 -3 -8 -7 -33 -10 -55 -4 -22 -10 -56 -15 -75 -5 -19 -11 -57 -15 -84 -3 -27 -8 -52 -9 -55 -2 -3 -7 -37 -11 -76 -4 -38 -8 -72 -10 -75 -2 -3 -6 -37 -10 -75 -4 -39 -8 -83 -10 -100 -27 -234 -27 -786 -1 -1030 2 -16 7 -61 11 -100 3 -38 8 -77 10 -85 2 -8 7 -39 10 -69 4 -30 9 -63 11 -75 2 -12 9 -48 14 -81 9 -52 53 -270 64 -315 2 -8 14 -53 26 -100 12 -47 23 -89 24 -95 21 -91 136 -430 201 -590 66 -163 229 -501 305 -630 29 -49 60 -104 71 -122 38 -67 197 -312 209 -323 3 -3 30 -39 60 -80 29 -41 56 -77 60 -80 4 -3 11 -12 16 -21 16 -30 164 -208 267 -324 88 -98 308 -318 402 -402 107 -95 113 -100 215 -182 52 -42 97 -79 98 -83 2 -5 10 -8 18 -8 8 0 14 -4 14 -8 0 -4 32 -30 71 -57 39 -28 84 -60 99 -72 15 -13 32 -23 38 -23 6 0 12 -3 14 -8 2 -4 35 -27 73 -52 39 -24 72 -47 75 -50 5 -6 130 -80 265 -157 65 -38 234 -126 245 -129 3 0 46 -20 95 -43 140 -66 185 -86 260 -116 39 -15 84 -33 100 -40 54 -23 388 -133 470 -155 95 -26 260 -67 295 -74 124 -25 232 -46 265 -50 23 -4 52 -9 65 -11 14 -3 41 -8 60 -10 19 -3 49 -7 65 -10 29 -4 93 -11 180 -20 278 -28 793 -28 1050 0 345 38 755 118 1002 196 212 67 291 93 318 104 17 7 66 27 110 43 268 101 595 263 869 430 33 20 66 40 71 45 6 4 55 37 110 74 122 80 362 259 391 290 12 13 24 23 28 23 7 0 15 6 64 50 15 14 59 52 97 85 88 77 363 352 436 435 165 190 319 383 319 400 0 5 4 10 8 10 4 0 16 13 25 30 10 16 23 35 30 42 14 15 180 266 190 288 4 8 16 29 26 45 219 353 404 775 556 1265 12 39 51 188 60 230 2 8 13 53 24 100 20 84 64 329 77 425 3 28 7 57 9 65 2 8 6 47 10 85 4 39 8 81 10 93 20 127 28 733 12 897 -5 44 -10 105 -13 135 -3 30 -7 71 -9 90 -3 19 -7 58 -10 85 -3 28 -8 61 -10 75 -2 14 -7 45 -10 70 -4 25 -16 92 -27 150 -11 58 -22 116 -24 130 -3 14 -10 43 -16 65 -11 42 -16 64 -24 105 -24 119 -143 492 -217 680 -101 256 -260 581 -382 781 -5 10 -23 40 -40 68 -16 28 -33 51 -37 51 -5 0 -8 5 -8 12 0 19 -217 332 -290 418 -8 10 -22 28 -30 40 -17 25 -46 60 -144 174 -178 208 -455 481 -641 631 -20 17 -42 35 -49 40 -6 6 -40 33 -76 60 -36 28 -67 52 -70 55 -3 3 -21 17 -40 30 -19 14 -39 28 -45 32 -31 25 -172 121 -250 171 -49 31 -95 60 -101 64 -12 9 -41 26 -103 60 -25 14 -50 29 -56 33 -67 49 -471 242 -672 321 -13 5 -33 13 -45 19 -13 5 -50 19 -83 30 -33 12 -69 25 -80 30 -57 25 -298 95 -477 140 -190 47 -477 101 -613 116 -33 3 -62 8 -65 9 -3 2 -48 6 -100 10 -52 4 -108 9 -125 12 -34 5 -661 13 -667 8z" transform="translate(0.000000,1080.000000) scale(0.100000,-0.100000)"/></g></svg>
|
||||
|
||||
|
Before Width: | Height: | Size: 3.5 KiB After Width: | Height: | Size: 3.5 KiB |
+1
-1
@@ -1,2 +1,2 @@
|
||||
[pytest]
|
||||
asyncio_mode = auto
|
||||
asyncio_mode = auto
|
||||
|
||||
Reference in New Issue
Block a user