Skip to content

Instantly share code, notes, and snippets.

@dnebing
dnebing / com.liferay.captcha.configuration.CaptchaConfiguration.config
Created May 13, 2026 20:00
Liferay Service Platform - com.liferay.captcha.configuration.CaptchaConfiguration.config
captchaEngine="com.liferay.captcha.simplecaptcha.SimpleCaptchaImpl"
createAccountCaptchaEnabled=B"true"
maxChallenges=I"-1"
messageBoardsEditCategoryCaptchaEnabled=B"false"
messageBoardsEditMessageCaptchaEnabled=B"false"
reCaptchaNoScriptURL="https://www.google.com/recaptcha/api/fallback?k\="
reCaptchaPrivateKey=""
reCaptchaPublicKey=""
reCaptchaScriptURL="https://www.google.com/recaptcha/api.js"
reCaptchaVerifyURL="https://www.google.com/recaptcha/api/siteverify"
@dnebing
dnebing / com.liferay.frontend.js.web.internal.session.timeout.configuration.SessionTimeoutConfiguration.config
Created May 13, 2026 19:59
Liferay Service Platform - com.liferay.frontend.js.web.internal.session.timeout.configuration.SessionTimeoutConfiguration.config
autoExtend=B"true"
autoExtendOffset=I"70"
@dnebing
dnebing / portal-ext.properties
Last active May 13, 2026 20:05
Liferay Service Platform - Shared portal-ext.properties
#############################################################
## ##
## portal-ext.properties file ##
## ##
## Controls the basic settings and setup for Liferay. ##
## Setup this file before starting Liferay the first time. ##
## ##
#############################################################
# Pick the screen name to use for the administrator account
@dnebing
dnebing / create-react-cx
Created September 17, 2024 20:06
This is a script for Macs to create new Liferay React Custom Element Client Extensions.
#!/bin/bash
# Function to display the welcome message
welcome() {
echo "Welcome to the create-react-cx script!"
echo "This script will help you create a new React app that leverages Liferay's version of React."
echo "By the time the script is finished, you will have a basic Liferay React Custom Element Client Extension."
echo
}
@dnebing
dnebing / generate-client
Created September 17, 2024 15:06
This is a full script to generate a client module after merging multiple Liferay OpenAPI Headless specs.
#!/usr/bin/env bash
# Enable strict mode
set -euo pipefail
# Declare associative arrays
declare -A file_object_map
declare -A operationId_counts
declare -A operationId_occurrences
@dnebing
dnebing / merge-apis
Created September 16, 2024 03:19
This is a script used to process all of the separate OpenAPI yaml files and can merge them into a single yaml file ready to generate a client.
#!/usr/bin/env bash
# Enable strict mode
set -euo pipefail
# Declare associative arrays
declare -A file_object_map
declare -A operationId_counts
declare -A operationId_occurrences
@dnebing
dnebing / Comment_Test_Structure.json
Created September 28, 2023 17:04
This is the JSON for the structure used with the comment custom fragment
{
"availableLanguageIds": [
"en_US"
],
"contentType": "journal",
"dataDefinitionFields": [
{
"customProperties": {
"labelAtStructureLevel": true,
"confirmationErrorMessage": {
@dnebing
dnebing / rename.sql
Created May 13, 2020 21:43
SQL For renaming Liferay tables to mixed case.
RENAME TABLE account_ TO Account_;
RENAME TABLE address TO Address;
RENAME TABLE announcementsdelivery TO AnnouncementsDelivery;
RENAME TABLE announcementsentry TO AnnouncementsEntry;
RENAME TABLE announcementsflag TO AnnouncementsFlag;
RENAME TABLE assetcategory TO AssetCategory;
RENAME TABLE assetcategoryproperty TO AssetCategoryProperty;
RENAME TABLE assetentries_assetcategories TO AssetEntries_AssetCategories;
RENAME TABLE assetentries_assettags TO AssetEntries_AssetTags;
RENAME TABLE assetentry TO AssetEntry;
04-Nov-2019 12:06:59.000 WARNING [main] org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesThreads The web application [ROOT] appears to have started a thread named [Framework Event Dispatcher: Equinox Container: e743df6a-d310-496b-9895-8268e33fb53f] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
java.lang.Object.wait(Native Method)
java.lang.Object.wait(Object.java:502)
org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.getNextEvent(EventManager.java:400)
org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:336)
04-Nov-2019 12:06:59.001 WARNING [main] org.apache.catalina.loader.WebappClassLoaderBase.clearReferencesThreads The web application [ROOT] appears to have started a thread named [Refresh Thread: Equinox Container: e743df6a-d310-496b-9895-8268e33fb53f] but has failed to stop it. This is very likely to create a memory leak. Stack trace of thread:
java.lang.Object.wait(Native Method)
java.lang.Obje
@dnebing
dnebing / rest-openapi.yaml
Created September 3, 2019 15:28
This is my OpenAPI Yaml file for the Headless Vitamins API.
components:
schemas:
Vitamin:
description: Contains all of the data for a single vitamin or mineral.
properties:
name:
description: The vitamin or mineral name.
type: string
id:
description: The vitamin or mineral internal ID.