Change-Id: Ic853d3aecc19de80751fcd9aab9dbe853d4c0114
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/1845
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Sharath George
| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,44 @@ |
| 0 |
+Name: erlang |
|
| 1 |
+Summary: erlang |
|
| 2 |
+Version: 19.1 |
|
| 3 |
+Release: 1%{?dist}
|
|
| 4 |
+Group: Development/Languages |
|
| 5 |
+Vendor: VMware, Inc. |
|
| 6 |
+Distribution: Photon |
|
| 7 |
+License: ASL2.0 |
|
| 8 |
+URL: http://erlang.com |
|
| 9 |
+BuildArch: x86_64 |
|
| 10 |
+Source0: OTP-%{version}.tar.gz
|
|
| 11 |
+%define sha1 OTP-19.1=e5e0fa26b0128e50904c57fd9d77b798df309c84 |
|
| 12 |
+ |
|
| 13 |
+%description |
|
| 14 |
+erlang programming language |
|
| 15 |
+ |
|
| 16 |
+%prep |
|
| 17 |
+%setup -q -n otp-OTP-%{version}
|
|
| 18 |
+ |
|
| 19 |
+%build |
|
| 20 |
+export ERL_TOP=`pwd` |
|
| 21 |
+./otp_build autoconf |
|
| 22 |
+./configure \ |
|
| 23 |
+ --prefix=%{_prefix}
|
|
| 24 |
+ |
|
| 25 |
+make |
|
| 26 |
+ |
|
| 27 |
+%install |
|
| 28 |
+ |
|
| 29 |
+make install DESTDIR=$RPM_BUILD_ROOT |
|
| 30 |
+ |
|
| 31 |
+%post |
|
| 32 |
+ |
|
| 33 |
+%files |
|
| 34 |
+%defattr(-,root,root) |
|
| 35 |
+%{_bindir}/*
|
|
| 36 |
+%{_libdir}/*
|
|
| 37 |
+%exclude /usr/src |
|
| 38 |
+%exclude %{_libdir}/debug
|
|
| 39 |
+ |
|
| 40 |
+%changelog |
|
| 41 |
+* Mon Dec 12 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 19.1-1 |
|
| 42 |
+- Initial. |
|
| 43 |
+ |
| 0 | 44 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,17 @@ |
| 0 |
+[Unit] |
|
| 1 |
+Description=RabbitMQ broker |
|
| 2 |
+After=network.target epmd@0.0.0.0.socket |
|
| 3 |
+Wants=network.target epmd@0.0.0.0.socket |
|
| 4 |
+ |
|
| 5 |
+[Service] |
|
| 6 |
+Type=notify |
|
| 7 |
+User=rabbitmq |
|
| 8 |
+Group=rabbitmq |
|
| 9 |
+NotifyAccess=all |
|
| 10 |
+TimeoutStartSec=3600 |
|
| 11 |
+WorkingDirectory=/var/lib/rabbitmq |
|
| 12 |
+ExecStart=/usr/lib/rabbitmq/lib/rabbitmq_server-0.0.0/sbin/rabbitmq-server |
|
| 13 |
+ExecStop=/usr/lib/rabbitmq/lib/rabbitmq_server-0.0.0/sbin/rabbitmqctl stop |
|
| 14 |
+ |
|
| 15 |
+[Install] |
|
| 16 |
+WantedBy=multi-user.target |
| 0 | 17 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,643 @@ |
| 0 |
+%% -*- mode: erlang -*- |
|
| 1 |
+%% ---------------------------------------------------------------------------- |
|
| 2 |
+%% RabbitMQ Sample Configuration File. |
|
| 3 |
+%% |
|
| 4 |
+%% See http://www.rabbitmq.com/configure.html for details. |
|
| 5 |
+%% ---------------------------------------------------------------------------- |
|
| 6 |
+[ |
|
| 7 |
+ {rabbit,
|
|
| 8 |
+ [%% |
|
| 9 |
+ %% Network Connectivity |
|
| 10 |
+ %% ==================== |
|
| 11 |
+ %% |
|
| 12 |
+ |
|
| 13 |
+ %% By default, RabbitMQ will listen on all interfaces, using |
|
| 14 |
+ %% the standard (reserved) AMQP port. |
|
| 15 |
+ %% |
|
| 16 |
+ %% {tcp_listeners, [5672]},
|
|
| 17 |
+ |
|
| 18 |
+ %% To listen on a specific interface, provide a tuple of {IpAddress, Port}.
|
|
| 19 |
+ %% For example, to listen only on localhost for both IPv4 and IPv6: |
|
| 20 |
+ %% |
|
| 21 |
+ %% {tcp_listeners, [{"127.0.0.1", 5672},
|
|
| 22 |
+ %% {"::1", 5672}]},
|
|
| 23 |
+ |
|
| 24 |
+ %% SSL listeners are configured in the same fashion as TCP listeners, |
|
| 25 |
+ %% including the option to control the choice of interface. |
|
| 26 |
+ %% |
|
| 27 |
+ %% {ssl_listeners, [5671]},
|
|
| 28 |
+ |
|
| 29 |
+ %% Number of Erlang processes that will accept connections for the TCP |
|
| 30 |
+ %% and SSL listeners. |
|
| 31 |
+ %% |
|
| 32 |
+ %% {num_tcp_acceptors, 10},
|
|
| 33 |
+ %% {num_ssl_acceptors, 1},
|
|
| 34 |
+ |
|
| 35 |
+ %% Maximum time for AMQP 0-8/0-9/0-9-1 handshake (after socket connection |
|
| 36 |
+ %% and SSL handshake), in milliseconds. |
|
| 37 |
+ %% |
|
| 38 |
+ %% {handshake_timeout, 10000},
|
|
| 39 |
+ |
|
| 40 |
+ %% Log levels (currently just used for connection logging). |
|
| 41 |
+ %% One of 'debug', 'info', 'warning', 'error' or 'none', in decreasing |
|
| 42 |
+ %% order of verbosity. Defaults to 'info'. |
|
| 43 |
+ %% |
|
| 44 |
+ %% {log_levels, [{connection, info}, {channel, info}]},
|
|
| 45 |
+ |
|
| 46 |
+ %% Set to 'true' to perform reverse DNS lookups when accepting a |
|
| 47 |
+ %% connection. Hostnames will then be shown instead of IP addresses |
|
| 48 |
+ %% in rabbitmqctl and the management plugin. |
|
| 49 |
+ %% |
|
| 50 |
+ %% {reverse_dns_lookups, true},
|
|
| 51 |
+ |
|
| 52 |
+ %% |
|
| 53 |
+ %% Security / AAA |
|
| 54 |
+ %% ============== |
|
| 55 |
+ %% |
|
| 56 |
+ |
|
| 57 |
+ %% The default "guest" user is only permitted to access the server |
|
| 58 |
+ %% via a loopback interface (e.g. localhost). |
|
| 59 |
+ %% {loopback_users, [<<"guest">>]},
|
|
| 60 |
+ %% |
|
| 61 |
+ %% Uncomment the following line if you want to allow access to the |
|
| 62 |
+ %% guest user from anywhere on the network. |
|
| 63 |
+ %% {loopback_users, []},
|
|
| 64 |
+ |
|
| 65 |
+ %% Configuring SSL. |
|
| 66 |
+ %% See http://www.rabbitmq.com/ssl.html for full documentation. |
|
| 67 |
+ %% |
|
| 68 |
+ %% {ssl_options, [{cacertfile, "/path/to/testca/cacert.pem"},
|
|
| 69 |
+ %% {certfile, "/path/to/server/cert.pem"},
|
|
| 70 |
+ %% {keyfile, "/path/to/server/key.pem"},
|
|
| 71 |
+ %% {verify, verify_peer},
|
|
| 72 |
+ %% {fail_if_no_peer_cert, false}]},
|
|
| 73 |
+ |
|
| 74 |
+ %% Choose the available SASL mechanism(s) to expose. |
|
| 75 |
+ %% The two default (built in) mechanisms are 'PLAIN' and |
|
| 76 |
+ %% 'AMQPLAIN'. Additional mechanisms can be added via |
|
| 77 |
+ %% plugins. |
|
| 78 |
+ %% |
|
| 79 |
+ %% See http://www.rabbitmq.com/authentication.html for more details. |
|
| 80 |
+ %% |
|
| 81 |
+ %% {auth_mechanisms, ['PLAIN', 'AMQPLAIN']},
|
|
| 82 |
+ |
|
| 83 |
+ %% Select an authentication database to use. RabbitMQ comes bundled |
|
| 84 |
+ %% with a built-in auth-database, based on mnesia. |
|
| 85 |
+ %% |
|
| 86 |
+ %% {auth_backends, [rabbit_auth_backend_internal]},
|
|
| 87 |
+ |
|
| 88 |
+ %% Configurations supporting the rabbitmq_auth_mechanism_ssl and |
|
| 89 |
+ %% rabbitmq_auth_backend_ldap plugins. |
|
| 90 |
+ %% |
|
| 91 |
+ %% NB: These options require that the relevant plugin is enabled. |
|
| 92 |
+ %% See http://www.rabbitmq.com/plugins.html for further details. |
|
| 93 |
+ |
|
| 94 |
+ %% The RabbitMQ-auth-mechanism-ssl plugin makes it possible to |
|
| 95 |
+ %% authenticate a user based on the client's SSL certificate. |
|
| 96 |
+ %% |
|
| 97 |
+ %% To use auth-mechanism-ssl, add to or replace the auth_mechanisms |
|
| 98 |
+ %% list with the entry 'EXTERNAL'. |
|
| 99 |
+ %% |
|
| 100 |
+ %% {auth_mechanisms, ['EXTERNAL']},
|
|
| 101 |
+ |
|
| 102 |
+ %% The rabbitmq_auth_backend_ldap plugin allows the broker to |
|
| 103 |
+ %% perform authentication and authorisation by deferring to an |
|
| 104 |
+ %% external LDAP server. |
|
| 105 |
+ %% |
|
| 106 |
+ %% For more information about configuring the LDAP backend, see |
|
| 107 |
+ %% http://www.rabbitmq.com/ldap.html. |
|
| 108 |
+ %% |
|
| 109 |
+ %% Enable the LDAP auth backend by adding to or replacing the |
|
| 110 |
+ %% auth_backends entry: |
|
| 111 |
+ %% |
|
| 112 |
+ %% {auth_backends, [rabbit_auth_backend_ldap]},
|
|
| 113 |
+ |
|
| 114 |
+ %% This pertains to both the rabbitmq_auth_mechanism_ssl plugin and |
|
| 115 |
+ %% STOMP ssl_cert_login configurations. See the rabbitmq_stomp |
|
| 116 |
+ %% configuration section later in this file and the README in |
|
| 117 |
+ %% https://github.com/rabbitmq/rabbitmq-auth-mechanism-ssl for further |
|
| 118 |
+ %% details. |
|
| 119 |
+ %% |
|
| 120 |
+ %% To use the SSL cert's CN instead of its DN as the username |
|
| 121 |
+ %% |
|
| 122 |
+ %% {ssl_cert_login_from, common_name},
|
|
| 123 |
+ |
|
| 124 |
+ %% SSL handshake timeout, in milliseconds. |
|
| 125 |
+ %% |
|
| 126 |
+ %% {ssl_handshake_timeout, 5000},
|
|
| 127 |
+ |
|
| 128 |
+ %% Password hashing implementation. Will only affect newly |
|
| 129 |
+ %% created users. To recalculate hash for an existing user |
|
| 130 |
+ %% it's necessary to update her password. |
|
| 131 |
+ %% |
|
| 132 |
+ %% {password_hashing_module, rabbit_password_hashing_sha256},
|
|
| 133 |
+ |
|
| 134 |
+ %% |
|
| 135 |
+ %% Default User / VHost |
|
| 136 |
+ %% ==================== |
|
| 137 |
+ %% |
|
| 138 |
+ |
|
| 139 |
+ %% On first start RabbitMQ will create a vhost and a user. These |
|
| 140 |
+ %% config items control what gets created. See |
|
| 141 |
+ %% http://www.rabbitmq.com/access-control.html for further |
|
| 142 |
+ %% information about vhosts and access control. |
|
| 143 |
+ %% |
|
| 144 |
+ %% {default_vhost, <<"/">>},
|
|
| 145 |
+ %% {default_user, <<"guest">>},
|
|
| 146 |
+ %% {default_pass, <<"guest">>},
|
|
| 147 |
+ %% {default_permissions, [<<".*">>, <<".*">>, <<".*">>]},
|
|
| 148 |
+ |
|
| 149 |
+ %% Tags for default user |
|
| 150 |
+ %% |
|
| 151 |
+ %% For more details about tags, see the documentation for the |
|
| 152 |
+ %% Management Plugin at http://www.rabbitmq.com/management.html. |
|
| 153 |
+ %% |
|
| 154 |
+ %% {default_user_tags, [administrator]},
|
|
| 155 |
+ |
|
| 156 |
+ %% |
|
| 157 |
+ %% Additional network and protocol related configuration |
|
| 158 |
+ %% ===================================================== |
|
| 159 |
+ %% |
|
| 160 |
+ |
|
| 161 |
+ %% Set the default AMQP heartbeat delay (in seconds). |
|
| 162 |
+ %% |
|
| 163 |
+ %% {heartbeat, 600},
|
|
| 164 |
+ |
|
| 165 |
+ %% Set the max permissible size of an AMQP frame (in bytes). |
|
| 166 |
+ %% |
|
| 167 |
+ %% {frame_max, 131072},
|
|
| 168 |
+ |
|
| 169 |
+ %% Set the max frame size the server will accept before connection |
|
| 170 |
+ %% tuning occurs |
|
| 171 |
+ %% |
|
| 172 |
+ %% {initial_frame_max, 4096},
|
|
| 173 |
+ |
|
| 174 |
+ %% Set the max permissible number of channels per connection. |
|
| 175 |
+ %% 0 means "no limit". |
|
| 176 |
+ %% |
|
| 177 |
+ %% {channel_max, 128},
|
|
| 178 |
+ |
|
| 179 |
+ %% Customising Socket Options. |
|
| 180 |
+ %% |
|
| 181 |
+ %% See (http://www.erlang.org/doc/man/inet.html#setopts-2) for |
|
| 182 |
+ %% further documentation. |
|
| 183 |
+ %% |
|
| 184 |
+ %% {tcp_listen_options, [{backlog, 128},
|
|
| 185 |
+ %% {nodelay, true},
|
|
| 186 |
+ %% {exit_on_close, false}]},
|
|
| 187 |
+ |
|
| 188 |
+ %% |
|
| 189 |
+ %% Resource Limits & Flow Control |
|
| 190 |
+ %% ============================== |
|
| 191 |
+ %% |
|
| 192 |
+ %% See http://www.rabbitmq.com/memory.html for full details. |
|
| 193 |
+ |
|
| 194 |
+ %% Memory-based Flow Control threshold. |
|
| 195 |
+ %% |
|
| 196 |
+ %% {vm_memory_high_watermark, 0.4},
|
|
| 197 |
+ |
|
| 198 |
+ %% Alternatively, we can set a limit (in bytes) of RAM used by the node. |
|
| 199 |
+ %% |
|
| 200 |
+ %% {vm_memory_high_watermark, {absolute, 1073741824}},
|
|
| 201 |
+ %% |
|
| 202 |
+ %% Or you can set absolute value using memory units. |
|
| 203 |
+ %% |
|
| 204 |
+ %% {vm_memory_high_watermark, {absolute, "1024M"}},
|
|
| 205 |
+ %% |
|
| 206 |
+ %% Supported units suffixes: |
|
| 207 |
+ %% |
|
| 208 |
+ %% k, kiB: kibibytes (2^10 bytes) |
|
| 209 |
+ %% M, MiB: mebibytes (2^20) |
|
| 210 |
+ %% G, GiB: gibibytes (2^30) |
|
| 211 |
+ %% kB: kilobytes (10^3) |
|
| 212 |
+ %% MB: megabytes (10^6) |
|
| 213 |
+ %% GB: gigabytes (10^9) |
|
| 214 |
+ |
|
| 215 |
+ %% Fraction of the high watermark limit at which queues start to |
|
| 216 |
+ %% page message out to disc in order to free up memory. |
|
| 217 |
+ %% |
|
| 218 |
+ %% Values greater than 0.9 can be dangerous and should be used carefully. |
|
| 219 |
+ %% |
|
| 220 |
+ %% {vm_memory_high_watermark_paging_ratio, 0.5},
|
|
| 221 |
+ |
|
| 222 |
+ %% Interval (in milliseconds) at which we perform the check of the memory |
|
| 223 |
+ %% levels against the watermarks. |
|
| 224 |
+ %% |
|
| 225 |
+ %% {memory_monitor_interval, 2500},
|
|
| 226 |
+ |
|
| 227 |
+ %% Set disk free limit (in bytes). Once free disk space reaches this |
|
| 228 |
+ %% lower bound, a disk alarm will be set - see the documentation |
|
| 229 |
+ %% listed above for more details. |
|
| 230 |
+ %% |
|
| 231 |
+ %% {disk_free_limit, 50000000},
|
|
| 232 |
+ %% |
|
| 233 |
+ %% Or you can set it using memory units (same as in vm_memory_high_watermark) |
|
| 234 |
+ %% {disk_free_limit, "50MB"},
|
|
| 235 |
+ %% {disk_free_limit, "50000kB"},
|
|
| 236 |
+ %% {disk_free_limit, "2GB"},
|
|
| 237 |
+ |
|
| 238 |
+ %% Alternatively, we can set a limit relative to total available RAM. |
|
| 239 |
+ %% |
|
| 240 |
+ %% Values lower than 1.0 can be dangerous and should be used carefully. |
|
| 241 |
+ %% {disk_free_limit, {mem_relative, 2.0}},
|
|
| 242 |
+ |
|
| 243 |
+ %% |
|
| 244 |
+ %% Misc/Advanced Options |
|
| 245 |
+ %% ===================== |
|
| 246 |
+ %% |
|
| 247 |
+ %% NB: Change these only if you understand what you are doing! |
|
| 248 |
+ %% |
|
| 249 |
+ |
|
| 250 |
+ %% To announce custom properties to clients on connection: |
|
| 251 |
+ %% |
|
| 252 |
+ %% {server_properties, []},
|
|
| 253 |
+ |
|
| 254 |
+ %% How to respond to cluster partitions. |
|
| 255 |
+ %% See http://www.rabbitmq.com/partitions.html for further details. |
|
| 256 |
+ %% |
|
| 257 |
+ %% {cluster_partition_handling, ignore},
|
|
| 258 |
+ |
|
| 259 |
+ %% Make clustering happen *automatically* at startup - only applied |
|
| 260 |
+ %% to nodes that have just been reset or started for the first time. |
|
| 261 |
+ %% See http://www.rabbitmq.com/clustering.html#auto-config for |
|
| 262 |
+ %% further details. |
|
| 263 |
+ %% |
|
| 264 |
+ %% {cluster_nodes, {['rabbit@my.host.com'], disc}},
|
|
| 265 |
+ |
|
| 266 |
+ %% Interval (in milliseconds) at which we send keepalive messages |
|
| 267 |
+ %% to other cluster members. Note that this is not the same thing |
|
| 268 |
+ %% as net_ticktime; missed keepalive messages will not cause nodes |
|
| 269 |
+ %% to be considered down. |
|
| 270 |
+ %% |
|
| 271 |
+ %% {cluster_keepalive_interval, 10000},
|
|
| 272 |
+ |
|
| 273 |
+ %% Set (internal) statistics collection granularity. |
|
| 274 |
+ %% |
|
| 275 |
+ %% {collect_statistics, none},
|
|
| 276 |
+ |
|
| 277 |
+ %% Statistics collection interval (in milliseconds). |
|
| 278 |
+ %% |
|
| 279 |
+ %% {collect_statistics_interval, 5000},
|
|
| 280 |
+ |
|
| 281 |
+ %% Explicitly enable/disable hipe compilation. |
|
| 282 |
+ %% |
|
| 283 |
+ %% {hipe_compile, true},
|
|
| 284 |
+ |
|
| 285 |
+ %% Timeout used when waiting for Mnesia tables in a cluster to |
|
| 286 |
+ %% become available. |
|
| 287 |
+ %% |
|
| 288 |
+ %% {mnesia_table_loading_timeout, 30000},
|
|
| 289 |
+ |
|
| 290 |
+ %% Size in bytes below which to embed messages in the queue index. See |
|
| 291 |
+ %% http://www.rabbitmq.com/persistence-conf.html |
|
| 292 |
+ %% |
|
| 293 |
+ %% {queue_index_embed_msgs_below, 4096}
|
|
| 294 |
+ |
|
| 295 |
+ ]}, |
|
| 296 |
+ |
|
| 297 |
+ %% ---------------------------------------------------------------------------- |
|
| 298 |
+ %% Advanced Erlang Networking/Clustering Options. |
|
| 299 |
+ %% |
|
| 300 |
+ %% See http://www.rabbitmq.com/clustering.html for details |
|
| 301 |
+ %% ---------------------------------------------------------------------------- |
|
| 302 |
+ {kernel,
|
|
| 303 |
+ [%% Sets the net_kernel tick time. |
|
| 304 |
+ %% Please see http://erlang.org/doc/man/kernel_app.html and |
|
| 305 |
+ %% http://www.rabbitmq.com/nettick.html for further details. |
|
| 306 |
+ %% |
|
| 307 |
+ %% {net_ticktime, 60}
|
|
| 308 |
+ ]}, |
|
| 309 |
+ |
|
| 310 |
+ %% ---------------------------------------------------------------------------- |
|
| 311 |
+ %% RabbitMQ Management Plugin |
|
| 312 |
+ %% |
|
| 313 |
+ %% See http://www.rabbitmq.com/management.html for details |
|
| 314 |
+ %% ---------------------------------------------------------------------------- |
|
| 315 |
+ |
|
| 316 |
+ {rabbitmq_management,
|
|
| 317 |
+ [%% Pre-Load schema definitions from the following JSON file. See |
|
| 318 |
+ %% http://www.rabbitmq.com/management.html#load-definitions |
|
| 319 |
+ %% |
|
| 320 |
+ %% {load_definitions, "/path/to/schema.json"},
|
|
| 321 |
+ |
|
| 322 |
+ %% Log all requests to the management HTTP API to a file. |
|
| 323 |
+ %% |
|
| 324 |
+ %% {http_log_dir, "/path/to/access.log"},
|
|
| 325 |
+ |
|
| 326 |
+ %% Change the port on which the HTTP listener listens, |
|
| 327 |
+ %% specifying an interface for the web server to bind to. |
|
| 328 |
+ %% Also set the listener to use SSL and provide SSL options. |
|
| 329 |
+ %% |
|
| 330 |
+ %% {listener, [{port, 12345},
|
|
| 331 |
+ %% {ip, "127.0.0.1"},
|
|
| 332 |
+ %% {ssl, true},
|
|
| 333 |
+ %% {ssl_opts, [{cacertfile, "/path/to/cacert.pem"},
|
|
| 334 |
+ %% {certfile, "/path/to/cert.pem"},
|
|
| 335 |
+ %% {keyfile, "/path/to/key.pem"}]}]},
|
|
| 336 |
+ |
|
| 337 |
+ %% One of 'basic', 'detailed' or 'none'. See |
|
| 338 |
+ %% http://www.rabbitmq.com/management.html#fine-stats for more details. |
|
| 339 |
+ %% {rates_mode, basic},
|
|
| 340 |
+ |
|
| 341 |
+ %% Configure how long aggregated data (such as message rates and queue |
|
| 342 |
+ %% lengths) is retained. Please read the plugin's documentation in |
|
| 343 |
+ %% http://www.rabbitmq.com/management.html#configuration for more |
|
| 344 |
+ %% details. |
|
| 345 |
+ %% |
|
| 346 |
+ %% {sample_retention_policies,
|
|
| 347 |
+ %% [{global, [{60, 5}, {3600, 60}, {86400, 1200}]},
|
|
| 348 |
+ %% {basic, [{60, 5}, {3600, 60}]},
|
|
| 349 |
+ %% {detailed, [{10, 5}]}]}
|
|
| 350 |
+ ]}, |
|
| 351 |
+ |
|
| 352 |
+ %% ---------------------------------------------------------------------------- |
|
| 353 |
+ %% RabbitMQ Shovel Plugin |
|
| 354 |
+ %% |
|
| 355 |
+ %% See http://www.rabbitmq.com/shovel.html for details |
|
| 356 |
+ %% ---------------------------------------------------------------------------- |
|
| 357 |
+ |
|
| 358 |
+ {rabbitmq_shovel,
|
|
| 359 |
+ [{shovels,
|
|
| 360 |
+ [%% A named shovel worker. |
|
| 361 |
+ %% {my_first_shovel,
|
|
| 362 |
+ %% [ |
|
| 363 |
+ |
|
| 364 |
+ %% List the source broker(s) from which to consume. |
|
| 365 |
+ %% |
|
| 366 |
+ %% {sources,
|
|
| 367 |
+ %% [%% URI(s) and pre-declarations for all source broker(s). |
|
| 368 |
+ %% {brokers, ["amqp://user:password@host.domain/my_vhost"]},
|
|
| 369 |
+ %% {declarations, []}
|
|
| 370 |
+ %% ]}, |
|
| 371 |
+ |
|
| 372 |
+ %% List the destination broker(s) to publish to. |
|
| 373 |
+ %% {destinations,
|
|
| 374 |
+ %% [%% A singular version of the 'brokers' element. |
|
| 375 |
+ %% {broker, "amqp://"},
|
|
| 376 |
+ %% {declarations, []}
|
|
| 377 |
+ %% ]}, |
|
| 378 |
+ |
|
| 379 |
+ %% Name of the queue to shovel messages from. |
|
| 380 |
+ %% |
|
| 381 |
+ %% {queue, <<"your-queue-name-goes-here">>},
|
|
| 382 |
+ |
|
| 383 |
+ %% Optional prefetch count. |
|
| 384 |
+ %% |
|
| 385 |
+ %% {prefetch_count, 10},
|
|
| 386 |
+ |
|
| 387 |
+ %% when to acknowledge messages: |
|
| 388 |
+ %% - no_ack: never (auto) |
|
| 389 |
+ %% - on_publish: after each message is republished |
|
| 390 |
+ %% - on_confirm: when the destination broker confirms receipt |
|
| 391 |
+ %% |
|
| 392 |
+ %% {ack_mode, on_confirm},
|
|
| 393 |
+ |
|
| 394 |
+ %% Overwrite fields of the outbound basic.publish. |
|
| 395 |
+ %% |
|
| 396 |
+ %% {publish_fields, [{exchange, <<"my_exchange">>},
|
|
| 397 |
+ %% {routing_key, <<"from_shovel">>}]},
|
|
| 398 |
+ |
|
| 399 |
+ %% Static list of basic.properties to set on re-publication. |
|
| 400 |
+ %% |
|
| 401 |
+ %% {publish_properties, [{delivery_mode, 2}]},
|
|
| 402 |
+ |
|
| 403 |
+ %% The number of seconds to wait before attempting to |
|
| 404 |
+ %% reconnect in the event of a connection failure. |
|
| 405 |
+ %% |
|
| 406 |
+ %% {reconnect_delay, 2.5}
|
|
| 407 |
+ |
|
| 408 |
+ %% ]} %% End of my_first_shovel |
|
| 409 |
+ ]} |
|
| 410 |
+ %% Rather than specifying some values per-shovel, you can specify |
|
| 411 |
+ %% them for all shovels here. |
|
| 412 |
+ %% |
|
| 413 |
+ %% {defaults, [{prefetch_count, 0},
|
|
| 414 |
+ %% {ack_mode, on_confirm},
|
|
| 415 |
+ %% {publish_fields, []},
|
|
| 416 |
+ %% {publish_properties, [{delivery_mode, 2}]},
|
|
| 417 |
+ %% {reconnect_delay, 2.5}]}
|
|
| 418 |
+ ]}, |
|
| 419 |
+ |
|
| 420 |
+ %% ---------------------------------------------------------------------------- |
|
| 421 |
+ %% RabbitMQ Stomp Adapter |
|
| 422 |
+ %% |
|
| 423 |
+ %% See http://www.rabbitmq.com/stomp.html for details |
|
| 424 |
+ %% ---------------------------------------------------------------------------- |
|
| 425 |
+ |
|
| 426 |
+ {rabbitmq_stomp,
|
|
| 427 |
+ [%% Network Configuration - the format is generally the same as for the broker |
|
| 428 |
+ |
|
| 429 |
+ %% Listen only on localhost (ipv4 & ipv6) on a specific port. |
|
| 430 |
+ %% {tcp_listeners, [{"127.0.0.1", 61613},
|
|
| 431 |
+ %% {"::1", 61613}]},
|
|
| 432 |
+ |
|
| 433 |
+ %% Listen for SSL connections on a specific port. |
|
| 434 |
+ %% {ssl_listeners, [61614]},
|
|
| 435 |
+ |
|
| 436 |
+ %% Number of Erlang processes that will accept connections for the TCP |
|
| 437 |
+ %% and SSL listeners. |
|
| 438 |
+ %% |
|
| 439 |
+ %% {num_tcp_acceptors, 10},
|
|
| 440 |
+ %% {num_ssl_acceptors, 1},
|
|
| 441 |
+ |
|
| 442 |
+ %% Additional SSL options |
|
| 443 |
+ |
|
| 444 |
+ %% Extract a name from the client's certificate when using SSL. |
|
| 445 |
+ %% |
|
| 446 |
+ %% {ssl_cert_login, true},
|
|
| 447 |
+ |
|
| 448 |
+ %% Set a default user name and password. This is used as the default login |
|
| 449 |
+ %% whenever a CONNECT frame omits the login and passcode headers. |
|
| 450 |
+ %% |
|
| 451 |
+ %% Please note that setting this will allow clients to connect without |
|
| 452 |
+ %% authenticating! |
|
| 453 |
+ %% |
|
| 454 |
+ %% {default_user, [{login, "guest"},
|
|
| 455 |
+ %% {passcode, "guest"}]},
|
|
| 456 |
+ |
|
| 457 |
+ %% If a default user is configured, or you have configured use SSL client |
|
| 458 |
+ %% certificate based authentication, you can choose to allow clients to |
|
| 459 |
+ %% omit the CONNECT frame entirely. If set to true, the client is |
|
| 460 |
+ %% automatically connected as the default user or user supplied in the |
|
| 461 |
+ %% SSL certificate whenever the first frame sent on a session is not a |
|
| 462 |
+ %% CONNECT frame. |
|
| 463 |
+ %% |
|
| 464 |
+ %% {implicit_connect, true}
|
|
| 465 |
+ ]}, |
|
| 466 |
+ |
|
| 467 |
+ %% ---------------------------------------------------------------------------- |
|
| 468 |
+ %% RabbitMQ MQTT Adapter |
|
| 469 |
+ %% |
|
| 470 |
+ %% See https://github.com/rabbitmq/rabbitmq-mqtt/blob/stable/README.md |
|
| 471 |
+ %% for details |
|
| 472 |
+ %% ---------------------------------------------------------------------------- |
|
| 473 |
+ |
|
| 474 |
+ {rabbitmq_mqtt,
|
|
| 475 |
+ [%% Set the default user name and password. Will be used as the default login |
|
| 476 |
+ %% if a connecting client provides no other login details. |
|
| 477 |
+ %% |
|
| 478 |
+ %% Please note that setting this will allow clients to connect without |
|
| 479 |
+ %% authenticating! |
|
| 480 |
+ %% |
|
| 481 |
+ %% {default_user, <<"guest">>},
|
|
| 482 |
+ %% {default_pass, <<"guest">>},
|
|
| 483 |
+ |
|
| 484 |
+ %% Enable anonymous access. If this is set to false, clients MUST provide |
|
| 485 |
+ %% login information in order to connect. See the default_user/default_pass |
|
| 486 |
+ %% configuration elements for managing logins without authentication. |
|
| 487 |
+ %% |
|
| 488 |
+ %% {allow_anonymous, true},
|
|
| 489 |
+ |
|
| 490 |
+ %% If you have multiple chosts, specify the one to which the |
|
| 491 |
+ %% adapter connects. |
|
| 492 |
+ %% |
|
| 493 |
+ %% {vhost, <<"/">>},
|
|
| 494 |
+ |
|
| 495 |
+ %% Specify the exchange to which messages from MQTT clients are published. |
|
| 496 |
+ %% |
|
| 497 |
+ %% {exchange, <<"amq.topic">>},
|
|
| 498 |
+ |
|
| 499 |
+ %% Specify TTL (time to live) to control the lifetime of non-clean sessions. |
|
| 500 |
+ %% |
|
| 501 |
+ %% {subscription_ttl, 1800000},
|
|
| 502 |
+ |
|
| 503 |
+ %% Set the prefetch count (governing the maximum number of unacknowledged |
|
| 504 |
+ %% messages that will be delivered). |
|
| 505 |
+ %% |
|
| 506 |
+ %% {prefetch, 10},
|
|
| 507 |
+ |
|
| 508 |
+ %% TCP/SSL Configuration (as per the broker configuration). |
|
| 509 |
+ %% |
|
| 510 |
+ %% {tcp_listeners, [1883]},
|
|
| 511 |
+ %% {ssl_listeners, []},
|
|
| 512 |
+ |
|
| 513 |
+ %% Number of Erlang processes that will accept connections for the TCP |
|
| 514 |
+ %% and SSL listeners. |
|
| 515 |
+ %% |
|
| 516 |
+ %% {num_tcp_acceptors, 10},
|
|
| 517 |
+ %% {num_ssl_acceptors, 1},
|
|
| 518 |
+ |
|
| 519 |
+ %% TCP/Socket options (as per the broker configuration). |
|
| 520 |
+ %% |
|
| 521 |
+ %% {tcp_listen_options, [{backlog, 128},
|
|
| 522 |
+ %% {nodelay, true}]}
|
|
| 523 |
+ ]}, |
|
| 524 |
+ |
|
| 525 |
+ %% ---------------------------------------------------------------------------- |
|
| 526 |
+ %% RabbitMQ AMQP 1.0 Support |
|
| 527 |
+ %% |
|
| 528 |
+ %% See https://github.com/rabbitmq/rabbitmq-amqp1.0/blob/stable/README.md |
|
| 529 |
+ %% for details |
|
| 530 |
+ %% ---------------------------------------------------------------------------- |
|
| 531 |
+ |
|
| 532 |
+ {rabbitmq_amqp1_0,
|
|
| 533 |
+ [%% Connections that are not authenticated with SASL will connect as this |
|
| 534 |
+ %% account. See the README for more information. |
|
| 535 |
+ %% |
|
| 536 |
+ %% Please note that setting this will allow clients to connect without |
|
| 537 |
+ %% authenticating! |
|
| 538 |
+ %% |
|
| 539 |
+ %% {default_user, "guest"},
|
|
| 540 |
+ |
|
| 541 |
+ %% Enable protocol strict mode. See the README for more information. |
|
| 542 |
+ %% |
|
| 543 |
+ %% {protocol_strict_mode, false}
|
|
| 544 |
+ ]}, |
|
| 545 |
+ |
|
| 546 |
+ %% ---------------------------------------------------------------------------- |
|
| 547 |
+ %% RabbitMQ LDAP Plugin |
|
| 548 |
+ %% |
|
| 549 |
+ %% See http://www.rabbitmq.com/ldap.html for details. |
|
| 550 |
+ %% |
|
| 551 |
+ %% ---------------------------------------------------------------------------- |
|
| 552 |
+ |
|
| 553 |
+ {rabbitmq_auth_backend_ldap,
|
|
| 554 |
+ [%% |
|
| 555 |
+ %% Connecting to the LDAP server(s) |
|
| 556 |
+ %% ================================ |
|
| 557 |
+ %% |
|
| 558 |
+ |
|
| 559 |
+ %% Specify servers to bind to. You *must* set this in order for the plugin |
|
| 560 |
+ %% to work properly. |
|
| 561 |
+ %% |
|
| 562 |
+ %% {servers, ["your-server-name-goes-here"]},
|
|
| 563 |
+ |
|
| 564 |
+ %% Connect to the LDAP server using SSL |
|
| 565 |
+ %% |
|
| 566 |
+ %% {use_ssl, false},
|
|
| 567 |
+ |
|
| 568 |
+ %% Specify the LDAP port to connect to |
|
| 569 |
+ %% |
|
| 570 |
+ %% {port, 389},
|
|
| 571 |
+ |
|
| 572 |
+ %% LDAP connection timeout, in milliseconds or 'infinity' |
|
| 573 |
+ %% |
|
| 574 |
+ %% {timeout, infinity},
|
|
| 575 |
+ |
|
| 576 |
+ %% Enable logging of LDAP queries. |
|
| 577 |
+ %% One of |
|
| 578 |
+ %% - false (no logging is performed) |
|
| 579 |
+ %% - true (verbose logging of the logic used by the plugin) |
|
| 580 |
+ %% - network (as true, but additionally logs LDAP network traffic) |
|
| 581 |
+ %% |
|
| 582 |
+ %% Defaults to false. |
|
| 583 |
+ %% |
|
| 584 |
+ %% {log, false},
|
|
| 585 |
+ |
|
| 586 |
+ %% |
|
| 587 |
+ %% Authentication |
|
| 588 |
+ %% ============== |
|
| 589 |
+ %% |
|
| 590 |
+ |
|
| 591 |
+ %% Pattern to convert the username given through AMQP to a DN before |
|
| 592 |
+ %% binding |
|
| 593 |
+ %% |
|
| 594 |
+ %% {user_dn_pattern, "cn=${username},ou=People,dc=example,dc=com"},
|
|
| 595 |
+ |
|
| 596 |
+ %% Alternatively, you can convert a username to a Distinguished |
|
| 597 |
+ %% Name via an LDAP lookup after binding. See the documentation for |
|
| 598 |
+ %% full details. |
|
| 599 |
+ |
|
| 600 |
+ %% When converting a username to a dn via a lookup, set these to |
|
| 601 |
+ %% the name of the attribute that represents the user name, and the |
|
| 602 |
+ %% base DN for the lookup query. |
|
| 603 |
+ %% |
|
| 604 |
+ %% {dn_lookup_attribute, "userPrincipalName"},
|
|
| 605 |
+ %% {dn_lookup_base, "DC=gopivotal,DC=com"},
|
|
| 606 |
+ |
|
| 607 |
+ %% Controls how to bind for authorisation queries and also to |
|
| 608 |
+ %% retrieve the details of users logging in without presenting a |
|
| 609 |
+ %% password (e.g., SASL EXTERNAL). |
|
| 610 |
+ %% One of |
|
| 611 |
+ %% - as_user (to bind as the authenticated user - requires a password) |
|
| 612 |
+ %% - anon (to bind anonymously) |
|
| 613 |
+ %% - {UserDN, Password} (to bind with a specified user name and password)
|
|
| 614 |
+ %% |
|
| 615 |
+ %% Defaults to 'as_user'. |
|
| 616 |
+ %% |
|
| 617 |
+ %% {other_bind, as_user},
|
|
| 618 |
+ |
|
| 619 |
+ %% |
|
| 620 |
+ %% Authorisation |
|
| 621 |
+ %% ============= |
|
| 622 |
+ %% |
|
| 623 |
+ |
|
| 624 |
+ %% The LDAP plugin can perform a variety of queries against your |
|
| 625 |
+ %% LDAP server to determine questions of authorisation. See |
|
| 626 |
+ %% http://www.rabbitmq.com/ldap.html#authorisation for more |
|
| 627 |
+ %% information. |
|
| 628 |
+ |
|
| 629 |
+ %% Set the query to use when determining vhost access |
|
| 630 |
+ %% |
|
| 631 |
+ %% {vhost_access_query, {in_group,
|
|
| 632 |
+ %% "ou=${vhost}-users,ou=vhosts,dc=example,dc=com"}},
|
|
| 633 |
+ |
|
| 634 |
+ %% Set the query to use when determining resource (e.g., queue) access |
|
| 635 |
+ %% |
|
| 636 |
+ %% {resource_access_query, {constant, true}},
|
|
| 637 |
+ |
|
| 638 |
+ %% Set queries to determine which tags a user has |
|
| 639 |
+ %% |
|
| 640 |
+ %% {tag_queries, []}
|
|
| 641 |
+ ]} |
|
| 642 |
+]. |
| 0 | 643 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,78 @@ |
| 0 |
+Name: rabbitmq-server |
|
| 1 |
+Summary: RabbitMQ messaging server |
|
| 2 |
+Version: 3.6.6 |
|
| 3 |
+Release: 1%{?dist}
|
|
| 4 |
+Group: Applications |
|
| 5 |
+Vendor: VMware, Inc. |
|
| 6 |
+Distribution: Photon |
|
| 7 |
+License: MPLv1.1 |
|
| 8 |
+URL: http://www.rabbitmq.com |
|
| 9 |
+BuildArch: x86_64 |
|
| 10 |
+Source0: %{name}-%{version}.tar.xz
|
|
| 11 |
+%define sha1 rabbitmq=fc6dbb566981e7810c14fe04521bed2acc3f85ca |
|
| 12 |
+Source1: rabbitmq.config |
|
| 13 |
+Source2: rabbitmq-server.service |
|
| 14 |
+Requires: erlang |
|
| 15 |
+Requires: shadow |
|
| 16 |
+Requires: sed |
|
| 17 |
+BuildRequires: erlang |
|
| 18 |
+BuildRequires: rsync |
|
| 19 |
+BuildRequires: zip |
|
| 20 |
+BuildRequires: libxslt |
|
| 21 |
+BuildRequires: python-xml |
|
| 22 |
+ |
|
| 23 |
+%description |
|
| 24 |
+rabbitmq messaging server |
|
| 25 |
+ |
|
| 26 |
+%prep |
|
| 27 |
+%setup -q |
|
| 28 |
+ |
|
| 29 |
+%build |
|
| 30 |
+make |
|
| 31 |
+ |
|
| 32 |
+%install |
|
| 33 |
+make install DESTDIR=$RPM_BUILD_ROOT \ |
|
| 34 |
+ PREFIX=%{_prefix} \
|
|
| 35 |
+ RMQ_ROOTDIR=/usr/lib/rabbitmq/ |
|
| 36 |
+ |
|
| 37 |
+install -vdm755 %{buildroot}/var/lib/rabbitmq/
|
|
| 38 |
+install -vdm755 %{buildroot}/%{_sysconfdir}/rabbitmq/
|
|
| 39 |
+install -vdm755 %{buildroot}/usr/lib/systemd/system/
|
|
| 40 |
+ |
|
| 41 |
+cp %{SOURCE1} %{buildroot}/%{_sysconfdir}/rabbitmq/
|
|
| 42 |
+cp %{SOURCE2} %{buildroot}/usr/lib/systemd/system/
|
|
| 43 |
+ |
|
| 44 |
+%pre |
|
| 45 |
+if ! getent group rabbitmq >/dev/null; then |
|
| 46 |
+ groupadd -r rabbitmq |
|
| 47 |
+fi |
|
| 48 |
+ |
|
| 49 |
+if ! getent passwd rabbitmq >/dev/null; then |
|
| 50 |
+ useradd -r -g rabbitmq -d %{_localstatedir}/lib/rabbitmq rabbitmq \
|
|
| 51 |
+ -s /sbin/nologin -c "RabbitMQ messaging server" |
|
| 52 |
+fi |
|
| 53 |
+ |
|
| 54 |
+%post |
|
| 55 |
+chown -R rabbitmq:rabbitmq /var/lib/rabbitmq |
|
| 56 |
+chown -R rabbitmq:rabbitmq /etc/rabbitmq |
|
| 57 |
+%systemd_post %{name}.service
|
|
| 58 |
+systemctl daemon-reload |
|
| 59 |
+ |
|
| 60 |
+%preun |
|
| 61 |
+%systemd_preun %{name}.service
|
|
| 62 |
+ |
|
| 63 |
+%postun |
|
| 64 |
+%systemd_postun_with_restart %{name}.service
|
|
| 65 |
+ |
|
| 66 |
+%clean |
|
| 67 |
+rm -rf $RPM_BUILD_ROOT |
|
| 68 |
+ |
|
| 69 |
+%files |
|
| 70 |
+%defattr(-,root,root) |
|
| 71 |
+%{_libdir}/*
|
|
| 72 |
+%{_sysconfdir}/*
|
|
| 73 |
+/var/lib/* |
|
| 74 |
+ |
|
| 75 |
+%changelog |
|
| 76 |
+* Mon Dec 12 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 3.6.6-1 |
|
| 77 |
+- Initial. |