-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstandalone.conf
More file actions
190 lines (159 loc) · 6.53 KB
/
standalone.conf
File metadata and controls
190 lines (159 loc) · 6.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
## -*- shell-script -*- ######################################################
## ##
## WildFly bootstrap Script Configuration ##
## ##
##############################################################################
echo "Running RUN CONF for jboss instance ${INSTANCE_NO}"
#
# This file is optional; it may be removed if not needed.
#
#
# Specify the maximum file descriptor limit, use "max" or "maximum" to use
# the default, as queried by the system.
#
# Defaults to "maximum"
#
#MAX_FD="maximum"
#
# Specify the profiler configuration file to load.
#
# Default is to not load profiler configuration file.
#
#PROFILER=""
#
# Specify the location of the Java home directory. If set then $JAVA will
# be defined to $JAVA_HOME/bin/java, else $JAVA will be "java".
#
#JAVA_HOME="/opt/java/jdk"
# tell linux glibc how many memory pools can be created that are used by malloc
# MALLOC_ARENA_MAX="5"
#
# Specify the exact Java VM executable to use.
#
#JAVA=""
if [ "x$JBOSS_MODULES_SYSTEM_PKGS" = "x" ]; then
JBOSS_MODULES_SYSTEM_PKGS="org.jboss.byteman"
fi
# Uncomment the following line to prevent manipulation of JVM options
# by shell scripts.
#
#PRESERVE_JAVA_OPTS=true
#
# Specify options to pass to the Java VM.
#
if [ "x$JAVA_OPTS" = "x" ]; then
JAVA_OPTS="-Xms64m -Xmx512m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true"
JAVA_OPTS="$JAVA_OPTS -Djboss.modules.system.pkgs=$JBOSS_MODULES_SYSTEM_PKGS -Djava.awt.headless=true"
else
echo "JAVA_OPTS already set in environment; overriding default settings with values: $JAVA_OPTS"
fi
# Sample JPDA settings for remote socket debugging
#JAVA_OPTS="$JAVA_OPTS -agentlib:jdwp=transport=dt_socket,address=8787,server=y,suspend=n"
# Sample JPDA settings for shared memory debugging
#JAVA_OPTS="$JAVA_OPTS -agentlib:jdwp=transport=dt_shmem,server=y,suspend=n,address=jboss"
# Uncomment to not use JBoss Modules lockless mode
#JAVA_OPTS="$JAVA_OPTS -Djboss.modules.lockless=false"
# Uncomment to gather JBoss Modules metrics
#JAVA_OPTS="$JAVA_OPTS -Djboss.modules.metrics=true"
# Uncomment to enable the experimental JDK 11 support for ByteBuddy
# ByteBuddy is the default bytecode provider of Hibernate ORM
#JAVA_OPTS="$JAVA_OPTS -Dnet.bytebuddy.experimental=true"
# Uncomment this to run with a security manager enabled
# SECMGR="true"
# Uncomment this in order to be able to run WildFly on FreeBSD
# when you get "epoll_create function not implemented" message in dmesg output
#JAVA_OPTS="$JAVA_OPTS -Djava.nio.channels.spi.SelectorProvider=sun.nio.ch.PollSelectorProvider"
# Uncomment this out to control garbage collection logging
# GC_LOG="true"
# Uncomment and edit to use a custom java.security file to override all the Java security properties
#JAVA_OPTS="$JAVA_OPTS -Djava.security.properties==/path/to/custom/java.security"
#
#set SERVER_CONF
SERVER_CONF="-DJBOSS_INSTANCE_NO=${INSTANCE_NO}"
SERVER_CONF="-Djboss.tx.node.id=UNIQUE_NODE_ID_${INSTANCE_NO}"
#Use the jboss.socket.binding.port-offset variable to avoid port conflicts
#between multi-instances
if [ "x$INSTANCE_NO" != "x" ]; then
if [ ${INSTANCE_NO} -gt 0 ]; then
INSTANCE_NO=$((${INSTANCE_NO}-1))
fi
echo "Setting up JBOSS_SOCKET_BINDING_PORT_OFFSET=[$INSTANCE_NO]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.socket.binding.port-offset=$((${INSTANCE_NO}-1))"
else
SERVER_OPTS="-Djboss.socket.binding.port-offset=${INSTANCE_NO}"
fi
fi
#set bind address & their respective ports
if [ "x$JBOSS_BIND_ADDRESS_MANAGEMENT" != "x" ]; then
echo "Setting up JBOSS_BIND_ADDRESS_MANAGEMENT=[$JBOSS_BIND_ADDRESS_MANAGEMENT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.bind.address.management=${JBOSS_BIND_ADDRESS_MANAGEMENT}"
else
SERVER_OPTS="-Djboss.bind.address.management=${JBOSS_BIND_ADDRESS_MANAGEMENT}"
fi
fi
if [ "x$JBOSS_MANAGEMENT_HTTP_PORT" != "x" ]; then
echo "Setting up JBOSS_MANAGEMENT_HTTP_PORT=[$JBOSS_MANAGEMENT_HTTP_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.management.http.port=${JBOSS_MANAGEMENT_HTTP_PORT}"
else
SERVER_OPTS="-Djboss.management.http.port=${JBOSS_MANAGEMENT_HTTP_PORT}"
fi
fi
if [ "x$JBOSS_MANAGEMENT_HTTPS_PORT" != "x" ]; then
echo "Setting up JBOSS_MANAGEMENT_HTTPS_PORT=[$JBOSS_MANAGEMENT_HTTPS_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.management.https.port=${JBOSS_MANAGEMENT_HTTPS_PORT}"
else
SERVER_OPTS="-Djboss.management.https.port=${JBOSS_MANAGEMENT_HTTPS_PORT}"
fi
fi
if [ "x$JBOSS_BIND_ADDRESS" != "x" ]; then
echo "Setting up JBOSS_BIND_ADDRESS=[$JBOSS_BIND_ADDRESS]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.bind.address=${JBOSS_BIND_ADDRESS}"
else
SERVER_OPTS="-Djboss.bind.address=${JBOSS_BIND_ADDRESS}"
fi
fi
if [ "x$JBOSS_AJP_PORT" != "x" ]; then
echo "Setting up JBOSS_AJP_PORT=[$JBOSS_AJP_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.ajp.port=${JBOSS_AJP_PORT}"
else
SERVER_OPTS="-Djboss.ajp.port=${JBOSS_AJP_PORT}"
fi
fi
if [ "x$JBOSS_HTTP_PORT" != "x" ]; then
echo "Setting up JBOSS_HTTP_PORT=[$JBOSS_HTTP_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.http.port=${JBOSS_HTTP_PORT}"
else
SERVER_OPTS="-Djboss.http.port=${JBOSS_HTTP_PORT}"
fi
fi
if [ "x$JBOSS_HTTPS_PORT" != "x" ]; then
echo "Setting up JBOSS_HTTPS_PORT=[$JBOSS_HTTPS_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.https.port=${JBOSS_HTTPS_PORT}"
else
SERVER_OPTS="-Djboss.https.port=${JBOSS_HTTPS_PORT}"
fi
fi
if [ "x$TXN_RECOVERY_ENVIRONMENT_PORT" != "x" ]; then
echo "Setting up TXN_RECOVERY_ENVIRONMENT_PORT=[$TXN_RECOVERY_ENVIRONMENT_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.txn.recovery.environment=${TXN_RECOVERY_ENVIRONMENT_PORT}"
else
SERVER_OPTS="-Djboss.txn.recovery.environment=${TXN_RECOVERY_ENVIRONMENT_PORT}"
fi
fi
if [ "x$TXN_STATUS_MANAGER_PORT" != "x" ]; then
echo "Setting up TXN_STATUS_MANAGER_PORT=[$TXN_STATUS_MANAGER_PORT]"
if [ "x$SERVER_OPTS" != "x" ]; then
SERVER_OPTS="${SERVER_OPTS} -Djboss.txn.status.manager=${TXN_STATUS_MANAGER_PORT}"
else
SERVER_OPTS="-Djboss.txn.status.manager=${TXN_STATUS_MANAGER_PORT}"
fi
fi