1 | /**
|
2 | * Copyright 2017-2018 F5 Networks, Inc.
|
3 | *
|
4 | * Licensed under the Apache License, Version 2.0 (the "License");
|
5 | * you may not use this file except in compliance with the License.
|
6 | * You may obtain a copy of the License at
|
7 | *
|
8 | * http://www.apache.org/licenses/LICENSE-2.0
|
9 | *
|
10 | * Unless required by applicable law or agreed to in writing, software
|
11 | * distributed under the License is distributed on an "AS IS" BASIS,
|
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13 | * See the License for the specific language governing permissions and
|
14 | * limitations under the License.
|
15 | */
|
16 |
|
17 | ;
|
18 |
|
19 | const LOCAL_PUBLIC_KEY_DIR = '/config/cloud/keys/';
|
20 |
|
21 | /**
|
22 | * Constants used across two or more files
|
23 | *
|
24 | * @module
|
25 | */
|
26 | module.exports = {
|
27 | /** @constant */
|
28 | KEYS: {
|
29 | LOCAL_PUBLIC_KEY_DIR,
|
30 | LOCAL_PUBLIC_KEY_PATH: `${LOCAL_PUBLIC_KEY_DIR}cloudLocalPublic.pub`,
|
31 | LOCAL_PRIVATE_KEY: 'cloudLibsLocalPrivate.key',
|
32 | LOCAL_PRIVATE_KEY_FOLDER: 'CloudLibsLocal'
|
33 | },
|
34 | /** @constant */
|
35 | PRODUCTS: {
|
36 | BIGIP: 'BIG-IP',
|
37 | BIGIQ: 'BIG-IQ'
|
38 | },
|
39 | /** @constant */
|
40 | REG_EXPS: {
|
41 | UUID: new RegExp(/^[A-F\d]{8}-[A-F\d]{4}-4[A-F\d]{3}-[89AB][A-F\d]{3}-[A-F\d]{12}$/i),
|
42 | KEY_SUFFIX: new RegExp(/\.key$/)
|
43 | },
|
44 | /** @constant */
|
45 | LICENSE_API_TYPES: {
|
46 | REG_KEY: 'REG_KEY',
|
47 | UTILITY: 'UTILITY',
|
48 | UTILITY_UNREACHABLE: 'UTILITY_UNREACHABLE'
|
49 | },
|
50 | BACKUP: {
|
51 | UCS_LOCAL_TMP_DIRECTORY: '/shared/tmp/ucs',
|
52 | PRIMARY_KEY_DIR: '/config/bigip/kstore/master',
|
53 | UNIT_KEY_DIR: '/config/bigip/kstore/.unitkey'
|
54 | }
|
55 | };
|