fix(strapi) add docs to build admin panel (#7369)

* fix(strapi) automatically build admin panel

* fix command and added docs

* replace init with args

* replace arg command

* remove initcontainer

* yarn strapi

* remove init and update docs.

* update docs

* remove extra args defaults

* fix test value

* remove comment

* add yarn run build initContainers

* update init initContainers

* update

* fix datbase host

* update

* update args

* update command

* replace npm with yarn

* remove init container

* update docs

* update word
This commit is contained in:
Xstar97TheNoob
2023-02-18 15:12:38 -05:00
committed by GitHub
parent 7db628e16f
commit e93bdedf88
4 changed files with 38 additions and 10 deletions

View File

@@ -25,9 +25,9 @@ sources:
- https://hub.docker.com/r/naskio/strapi
- https://truecharts.org/docs/charts/stable/strapi
- https://github.com/naskio/docker-strapi
version: 8.0.29
version: 8.0.30
annotations:
truecharts.org/catagories: |
- media
- cms
truecharts.org/SCALE-support: "true"
truecharts.org/grade: U

View File

@@ -0,0 +1,22 @@
# Installation Notes
- Create a `Jwt Secret` to be used to signed the JWT for Users-Permissions plugin.
- Create a `Admin Jwt Secret` to be used to sign the JWT for the Admin panel.
- Set `App Keys` as a json array:
- `['keya', 'keyb']`.
- Set `Node Environment` to **Development** initially.
- Optionally set `Public URL` to a FDQN with https, ex: `https://api.example.com`.
- Optionally set `Strapi License` to activate the Enterprise Edition.
- Enable/Disable `Strapi Disable Update Notifications` for strapi update notifications.
- Enable/Disable `Fast Refresh` for react near-instant feedback.
- `Extra Args` can be left empty for the standard defaults or get args from [strapi-new](https://strapi.io/documentation/developer-docs/latest/developer-resources/cli/CLI.html#strapi-new).
- After the app is installed you might get a `Content Security Policy` error. To solve this you have to manually shell into the app.
- Apps -> strapi -> 3 dot -> shell:
- run the following command to build the admin panel for v4:
```shell
npm run build
```
- Restart the app after the command is ran successfully.

View File

@@ -60,6 +60,11 @@ questions:
description: Production
- value: development
description: Development
- variable: PUBLIC_URL
label: Public URL
schema:
type: string
default: ""
- variable: STRAPI_LICENSE
label: Strapi License
description: The license key to activate the Enterprise Edition.

View File

@@ -12,12 +12,13 @@ podSecurityContext:
runAsGroup: 0
secretEnv:
JWT_SECRET: "my_jwt_secret"
ADMIN_JWT_SECRET: "my_admin_jwt_secret"
APP_KEYS: "my_app_keys"
JWT_SECRET: my_jwt_secret
ADMIN_JWT_SECRET: my_admin_jwt_secret
APP_KEYS: '["keya", "keyb"]'
env:
DATABASE_CLIENT: "postgres"
PORT: "{{ .Values.service.main.ports.main.port }}"
DATABASE_CLIENT: postgres
DATABASE_PORT: 5432
DATABASE_NAME: "{{ .Values.postgresql.postgresqlDatabase }}"
DATABASE_HOST:
@@ -30,7 +31,8 @@ env:
name: dbcreds
key: postgresql-password
# STRAPI_LICENSE
NODE_ENV: "production"
# PUBLIC_URL
NODE_ENV: development
STRAPI_DISABLE_UPDATE_NOTIFICATION: true
FAST_REFRESH: false
EXTRA_ARGS: ""
@@ -40,17 +42,16 @@ service:
ports:
main:
port: 1337
targetPort: 1337
persistence:
data:
enabled: true
mountPath: "/srv/app"
mountPath: /srv/app
# Enabled postgres
postgresql:
enabled: true
existingSecret: "dbcreds"
existingSecret: dbcreds
postgresqlUsername: strapi
postgresqlDatabase: strapi