Skip to content

Instantly share code, notes, and snippets.

<Context>
<Manager pathname=”” />
<Parameter name=”repository-address” value=”rmi://127.11.6.129:15099/hipporepository” override=”false”/>
<Parameter name=”repository-directory” value=”${catalina.base}/../repository” override=”false”/>
<Parameter name=”start-remote-server” value=”false” override=”false”/>
<Parameter name=”check-username” value=”liveuser” override=”false”/>
<Resource name=”mail/Session” auth=”Container” type=”javax.mail.Session” mail.smtp.host=”localhost”/>
@canhnt
canhnt / openshift-tomcat8-env.sh
Last active December 31, 2015 14:21
openshift-tomcat8-env
JAVA_HOME=$OPENSHIFT_DATA_DIR/bin/jre1.8.0_66
JAVA_ENDORSED_DIRS="$JAVA_HOME/endorsed"
CATALINA_HOME="$OPENSHIFT_DATA_DIR/bin/tomcat8/"
CATALINA_BASE="$OPENSHIFT_DATA_DIR/bin/tomcat8/"
CATALINA_PID="${CATALINA_BASE}/work/catalina.pid"
CLUSTER_ID="$(whoami)-$(hostname -f)"
MAX_HEAP=512
final InputStream pubKeyStream = getClass().getClassLoader().getResourceAsStream("pubkey.asc");
assertNotNull(pubKeyStream);
PGPPublicKeyRingCollection pubRingCollection = new PGPPublicKeyRingCollection(
PGPUtil.getDecoderStream(pubKeyStream),
new JcaKeyFingerprintCalculator());
final PGPPublicKeyRing pgpPublicKeyRing = pubRingCollection.getKeyRings().next();
assertNotNull(pgpPublicKeyRing);
final PGPPublicKey pgpPublicKey = pgpPublicKeyRing.getPublicKey();
@canhnt
canhnt / hippo-mvn-gen.sh
Last active August 29, 2015 14:19
Generate Hippo essential project (10GA milestone1)
mvn archetype:generate \
-DarchetypeGroupId=org.onehippo.cms7 \
-DarchetypeArtifactId=hippo-project-archetype \
-DarchetypeVersion=2.01.02-milestone-1 \
-DarchetypeRepository=http://maven.onehippo.com/maven2
<hst:link var="canonicalUrl" hippobean="${document}" canonical="true"/>
<hst:headContribution keyHint="canonical">
<link rel="canonical" href="${canonicalUrl}"/>
</hst:headContribution>
@canhnt
canhnt / hippo.sh
Last active August 29, 2015 14:04
Bash script to compile, run Hippo CMS project
#!/bin/bash
PROFILE_FILENAME=".hippo"
backup() {
echo "Move repository from $1 to $2"
mv $1 $2
exit 0
}
get_profiles(){
# remove commented lines