diff --git a/.vib/appsmith/goss/appsmith.yaml b/.vib/appsmith/goss/appsmith.yaml new file mode 100644 index 000000000000..f6d4221d0a23 --- /dev/null +++ b/.vib/appsmith/goss/appsmith.yaml @@ -0,0 +1,29 @@ +file: + /opt/appsmith: + exists: true + filetype: symlink + linked-to: /opt/bitnami/appsmith + /opt/bitnami/appsmith/templates/docker.env.sh: + exists: true + filetype: file + contains: + - /cat.*EOF/ + - APPSMITH_SUPERVISOR_USER +command: + check-server-init: + exec: java -jar /opt/bitnami/appsmith/backend/server.jar + exit-status: 1 + stdout: + - {{ .Env.APP_VERSION }} + - Starting ServerApplication + check-rts-init: + exec: cd /opt/appsmith/rts/ && node --require source-map-support/register server.js + exit-status: 1 + stderr: + - APPSMITH_API_BASE_URL +group: + appsmith: + exists: true +user: + appsmith: + exists: true diff --git a/.vib/appsmith/goss/goss.yaml b/.vib/appsmith/goss/goss.yaml new file mode 100644 index 000000000000..8b5222d8c615 --- /dev/null +++ b/.vib/appsmith/goss/goss.yaml @@ -0,0 +1,12 @@ +gossfile: + # Goss tests exclusive to the current container + ../../appsmith/goss/appsmith.yaml: {} + # Load scripts from .vib/common/goss/templates + ../../common/goss/templates/check-binaries.yaml: {} + ../../common/goss/templates/check-broken-symlinks.yaml: {} + ../../common/goss/templates/check-ca-certs.yaml: {} + ../../common/goss/templates/check-directories.yaml: {} + ../../common/goss/templates/check-files.yaml: {} + ../../common/goss/templates/check-linked-libraries.yaml: {} + ../../common/goss/templates/check-sed-in-place.yaml: {} + ../../common/goss/templates/check-spdx.yaml: {} diff --git a/.vib/appsmith/goss/vars.yaml b/.vib/appsmith/goss/vars.yaml new file mode 100644 index 000000000000..995c18a1e627 --- /dev/null +++ b/.vib/appsmith/goss/vars.yaml @@ -0,0 +1,33 @@ +binaries: + - java + - mongosh + - nginx + - node + - python + - render-template + - wait-for-port +directories: + - mode: "0775" + paths: + - /bitnami/appsmith + - /opt/bitnami/appsmith/conf + - /opt/bitnami/appsmith/logs + - /opt/bitnami/appsmith/tmp + - paths: + - /opt/bitnami/appsmith/backend/plugins + - /opt/bitnami/appsmith/editor + - /opt/bitnami/appsmith/templates/client +files: + - mode: "0664" + paths: + - /opt/bitnami/appsmith/conf/docker.env + - paths: + - /opt/bitnami/appsmith/editor/index.html + - /opt/bitnami/appsmith/backend/server.jar + - /opt/bitnami/appsmith/rts/package.json +linked_libraries: + timeout: 45000 +sed_in_place: + exclude_paths: + - /opt/bitnami/appsmith/rts/node_modules +root_dir: /opt/bitnami diff --git a/.vib/appsmith/vib-publish.json b/.vib/appsmith/vib-publish.json index 8b6fe8eab4e6..fdf73014d7fe 100644 --- a/.vib/appsmith/vib-publish.json +++ b/.vib/appsmith/vib-publish.json @@ -3,7 +3,8 @@ "resources": { "url": "{VIB_ENV_CONTAINER_URL}", "path": "{VIB_ENV_PATH}" - } + }, + "runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd" }, "phases": { "package": { @@ -77,9 +78,24 @@ "url": "{VIB_ENV_PACKAGES_JSON_URL}", "path": "/{VIB_ENV_PATH}", "authn": { - "header": "Authorization", - "token": "Bearer {VIB_ENV_GITHUB_TOKEN}" - } + "header": "Authorization", + "token": "Bearer {VIB_ENV_GITHUB_TOKEN}" + } + } + } + }, + { + "action_id": "goss", + "params": { + "resources": { + "path": "/.vib" + }, + "tests_file": "appsmith/goss/goss.yaml", + "vars_file": "appsmith/goss/vars.yaml", + "remote": { + "pod": { + "workload": "deploy-appsmith" + } } } } diff --git a/.vib/appsmith/vib-verify.json b/.vib/appsmith/vib-verify.json index a34e8aee9161..b0d999cb652d 100644 --- a/.vib/appsmith/vib-verify.json +++ b/.vib/appsmith/vib-verify.json @@ -3,7 +3,8 @@ "resources": { "url": "{SHA_ARCHIVE}", "path": "{VIB_ENV_PATH}" - } + }, + "runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd" }, "phases": { "package": { @@ -46,6 +47,21 @@ "OS" ] } + }, + { + "action_id": "goss", + "params": { + "resources": { + "path": "/.vib" + }, + "tests_file": "appsmith/goss/goss.yaml", + "vars_file": "appsmith/goss/vars.yaml", + "remote": { + "pod": { + "workload": "deploy-appsmith" + } + } + } } ] }