Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.

Commit

Permalink
Support virtual networks
Browse files Browse the repository at this point in the history
  • Loading branch information
deric committed Jul 13, 2018
1 parent 84ff35d commit 43930fc
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
17 changes: 16 additions & 1 deletion repo/packages/M/marathon/201/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@
"type" : "string"
},
"type" : "array"
},
"virtual_network_enabled": {
"description": "Enable virtual networking",
"type": "boolean",
"default": false
},
"virtual_network_name": {
"description": "The name of the virtual network to join",
"type": "string",
"default": "dcos"
},
"virtual_network_plugin_labels": {
"description": "Labels to pass to the virtual network plugin. Comma-separated key:value pairs. For example: k_0:v_0,k_1:v_1,...,k_n:v_n",
"type": "string",
"default": ""
}
},
"required" : [ "cpus", "mem", "instances" ],
Expand Down Expand Up @@ -433,4 +448,4 @@
},
"required" : [ "service", "jvm", "marathon" ],
"type" : "object"
}
}
5 changes: 5 additions & 0 deletions repo/packages/M/marathon/201/marathon.json.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,11 @@
{{/marathon.ssl-keystore-path}}
],
"env": {
{{#service.virtual_network_enabled}}
"ENABLE_VIRTUAL_NETWORK": "yes",
"VIRTUAL_NETWORK_NAME": "{{service.virtual_network_name}}",
"VIRTUAL_NETWORK_PLUGIN_LABELS": "{{service.virtual_network_plugin_labels}}",
{{/service.virtual_network_enabled}}
"JVM_OPTS": "-Xms{{jvm.heap-min}}m -Xmx{{jvm.heap-max}}m {{#jvm.opts}}{{jvm.opts}}{{/jvm.opts}}"
},
"cmd": "LIBPROCESS_PORT=$PORT1 && ./bin/start {{#marathon.access-control-allow-origin}}--access_control_allow_origin \"{{marathon.access-control-allow-origin}}\"{{/marathon.access-control-allow-origin}} {{#marathon.backup-location}}--backup_location \"{{marathon.backup-location}}\"{{/marathon.backup-location}} {{#marathon.checkpoint}} --checkpoint{{/marathon.checkpoint}}{{^marathon.checkpoint}}--disable_checkpoint{{/marathon.checkpoint}} {{#marathon.decline-offer-duration}}--decline_offer_duration \"{{marathon.decline-offer-duration}}\"{{/marathon.decline-offer-duration}} {{#marathon.default-accepted-resource-roles}}--default_accepted_resource_roles \"{{marathon.default-accepted-resource-roles}}\"{{/marathon.default-accepted-resource-roles}} {{#marathon.default-network-name}}--default_network_name \"{{marathon.default-network-name}}\"{{/marathon.default-network-name}} {{#marathon.disable-http}}--disable_http{{/marathon.disable-http}} {{#marathon.draining-seconds}}--draining_seconds \"{{marathon.draining-seconds}}\"{{/marathon.draining-seconds}} {{#marathon.enable-features}}--enable_features \"{{marathon.enable-features}}\"{{/marathon.enable-features}} {{#marathon.env-vars-prefix}}--env_vars_prefix \"{{marathon.env-vars-prefix}}\"{{/marathon.env-vars-prefix}} {{#marathon.event-stream-max-outstanding-messages}}--event_stream_max_outstanding_messages \"{{marathon.event-stream-max-outstanding-messages}}\"{{/marathon.event-stream-max-outstanding-messages}} {{#marathon.executor}}--executor \"{{marathon.executor}}\"{{/marathon.executor}} {{#marathon.failover-timeout}}--failover_timeout \"{{marathon.failover-timeout}}\"{{/marathon.failover-timeout}} --framework_name {{#marathon.framework-name}}{{marathon.framework-name}}{{/marathon.framework-name}}{{^marathon.framework-name}}{{service.name}}{{/marathon.framework-name}} {{#marathon.ha}} --ha{{/marathon.ha}}{{^marathon.ha}}--disable_ha{{/marathon.ha}} --hostname {{#marathon.hostname}}{{marathon.hostname}}{{/marathon.hostname}}{{^marathon.hostname}}$LIBPROCESS_IP{{/marathon.hostname}} {{#marathon.http-address}}--http_address \"{{marathon.http-address}}\"{{/marathon.http-address}} {{#marathon.http-compression}} --http_compression{{/marathon.http-compression}}{{^marathon.http-compression}}--disable_http_compression{{/marathon.http-compression}} {{#marathon.http-credentials}}--http_credentials \"{{marathon.http-credentials}}\"{{/marathon.http-credentials}} {{#marathon.http-max-concurrent-requests}}--http_max_concurrent_requests \"{{marathon.http-max-concurrent-requests}}\"{{/marathon.http-max-concurrent-requests}} --http_port {{#marathon.http-port}}{{marathon.http-port}}{{/marathon.http-port}}{{^marathon.http-port}} $PORT0 {{/marathon.http-port}} {{#marathon.http-realm}}--http_realm \"{{marathon.http-realm}}\"{{/marathon.http-realm}} {{#marathon.https-address}}--https_address \"{{marathon.https-address}}\"{{/marathon.https-address}} {{#marathon.ssl-keystore-path}}--https_port {{#marathon.https-port}}{{marathon.https-port}}{{/marathon.https-port}}{{^marathon.https-port}} $PORT2 {{/marathon.https-port}}{{/marathon.ssl-keystore-path}} {{#marathon.launch-token-refresh-interval}}--launch_token_refresh_interval \"{{marathon.launch-token-refresh-interval}}\"{{/marathon.launch-token-refresh-interval}} {{#marathon.launch-tokens}}--launch_tokens \"{{marathon.launch-tokens}}\"{{/marathon.launch-tokens}} {{#marathon.leader-proxy-connection-timeout}}--leader_proxy_connection_timeout \"{{marathon.leader-proxy-connection-timeout}}\"{{/marathon.leader-proxy-connection-timeout}} {{#marathon.leader-proxy-read-timeout}}--leader_proxy_read_timeout \"{{marathon.leader-proxy-read-timeout}}\"{{/marathon.leader-proxy-read-timeout}} {{#marathon.leader-proxy-ssl-ignore-hostname}}--leader_proxy_ssl_ignore_hostname \"{{marathon.leader-proxy-ssl-ignore-hostname}}\"{{/marathon.leader-proxy-ssl-ignore-hostname}} {{#marathon.local-port-max}}--local_port_max \"{{marathon.local-port-max}}\"{{/marathon.local-port-max}} {{#marathon.local-port-min}}--local_port_min \"{{marathon.local-port-min}}\"{{/marathon.local-port-min}} {{#marathon.logging-level}}--logging_level \"{{marathon.logging-level}}\"{{/marathon.logging-level}} {{#marathon.logstash}}--logstash \"{{marathon.logstash}}\"{{/marathon.logstash}} {{#marathon.master}}--master \"{{marathon.master}}\"{{/marathon.master}} {{#marathon.max-apps}}--max_apps \"{{marathon.max-apps}}\"{{/marathon.max-apps}} {{#marathon.max-instances-per-offer}}--max_instances_per_offer \"{{marathon.max-instances-per-offer}}\"{{/marathon.max-instances-per-offer}} {{#marathon.mesos-authentication}} --mesos_authentication{{/marathon.mesos-authentication}}{{^marathon.mesos-authentication}}--disable_mesos_authentication{{/marathon.mesos-authentication}} --mesos_authentication_principal {{#marathon.mesos-authentication-principal}}{{marathon.mesos-authentication-principal}}{{/marathon.mesos-authentication-principal}}{{^marathon.mesos-authentication-principal}}{{service.name}}{{/marathon.mesos-authentication-principal}} {{#marathon.mesos-authentication-secret}}--mesos_authentication_secret \"{{marathon.mesos-authentication-secret}}\"{{/marathon.mesos-authentication-secret}} {{#marathon.mesos-authentication-secret-file}}--mesos_authentication_secret_file \"{{marathon.mesos-authentication-secret-file}}\"{{/marathon.mesos-authentication-secret-file}} {{#marathon.mesos-bridge-name}}--mesos_bridge_name \"{{marathon.mesos-bridge-name}}\"{{/marathon.mesos-bridge-name}} {{#marathon.mesos-leader-ui-url}}--mesos_leader_ui_url \"{{marathon.mesos-leader-ui-url}}\"{{/marathon.mesos-leader-ui-url}} --mesos_role {{#marathon.mesos-role}}{{marathon.mesos-role}}{{/marathon.mesos-role}}{{^marathon.mesos-role}}{{service.name}}{{/marathon.mesos-role}} {{#marathon.mesos-user}}--mesos_user \"{{marathon.mesos-user}}\"{{/marathon.mesos-user}} {{#marathon.metrics}} --metrics{{/marathon.metrics}}{{^marathon.metrics}}--disable_metrics{{/marathon.metrics}} {{#marathon.min-revive-offers-interval}}--min_revive_offers_interval \"{{marathon.min-revive-offers-interval}}\"{{/marathon.min-revive-offers-interval}} {{#marathon.offer-matching-timeout}}--offer_matching_timeout \"{{marathon.offer-matching-timeout}}\"{{/marathon.offer-matching-timeout}} {{#marathon.on-elected-prepare-timeout}}--on_elected_prepare_timeout \"{{marathon.on-elected-prepare-timeout}}\"{{/marathon.on-elected-prepare-timeout}} {{#marathon.plugin-conf}}--plugin_conf \"{{marathon.plugin-conf}}\"{{/marathon.plugin-conf}} {{#marathon.plugin-dir}}--plugin_dir \"{{marathon.plugin-dir}}\"{{/marathon.plugin-dir}} {{#marathon.reconciliation-initial-delay}}--reconciliation_initial_delay \"{{marathon.reconciliation-initial-delay}}\"{{/marathon.reconciliation-initial-delay}} {{#marathon.reconciliation-interval}}--reconciliation_interval \"{{marathon.reconciliation-interval}}\"{{/marathon.reconciliation-interval}} {{#marathon.reporter-datadog}}--reporter_datadog \"{{marathon.reporter-datadog}}\"{{/marathon.reporter-datadog}} {{#marathon.reporter-graphite}}--reporter_graphite \"{{marathon.reporter-graphite}}\"{{/marathon.reporter-graphite}} {{#marathon.revive-offers-repetitions}}--revive_offers_repetitions \"{{marathon.revive-offers-repetitions}}\"{{/marathon.revive-offers-repetitions}} {{#marathon.scale-apps-initial-delay}}--scale_apps_initial_delay \"{{marathon.scale-apps-initial-delay}}\"{{/marathon.scale-apps-initial-delay}} {{#marathon.scale-apps-interval}}--scale_apps_interval \"{{marathon.scale-apps-interval}}\"{{/marathon.scale-apps-interval}} {{#marathon.sentry}}--sentry \"{{marathon.sentry}}\"{{/marathon.sentry}} {{#marathon.sentry-tags}}--sentry_tags \"{{marathon.sentry-tags}}\"{{/marathon.sentry-tags}} {{#marathon.ssl-keystore-password}}--ssl_keystore_password \"{{marathon.ssl-keystore-password}}\"{{/marathon.ssl-keystore-password}} {{#marathon.ssl-keystore-path}}--ssl_keystore_path \"{{marathon.ssl-keystore-path}}\"{{/marathon.ssl-keystore-path}} {{#marathon.store-cache}} --store_cache{{/marathon.store-cache}}{{^marathon.store-cache}}--disable_store_cache{{/marathon.store-cache}} {{#marathon.task-launch-confirm-timeout}}--task_launch_confirm_timeout \"{{marathon.task-launch-confirm-timeout}}\"{{/marathon.task-launch-confirm-timeout}} {{#marathon.task-launch-timeout}}--task_launch_timeout \"{{marathon.task-launch-timeout}}\"{{/marathon.task-launch-timeout}} {{#marathon.task-lost-expunge-initial-delay}}--task_lost_expunge_initial_delay \"{{marathon.task-lost-expunge-initial-delay}}\"{{/marathon.task-lost-expunge-initial-delay}} {{#marathon.task-lost-expunge-interval}}--task_lost_expunge_interval \"{{marathon.task-lost-expunge-interval}}\"{{/marathon.task-lost-expunge-interval}} {{#marathon.task-reservation-timeout}}--task_reservation_timeout \"{{marathon.task-reservation-timeout}}\"{{/marathon.task-reservation-timeout}} {{#marathon.webui-url}}--webui_url \"{{marathon.webui-url}}\"{{/marathon.webui-url}} --zk {{#marathon.zk}}{{marathon.zk}}{{/marathon.zk}}{{^marathon.zk}}zk://master.mesos:2181/universe/{{service.name}}{{/marathon.zk}} {{#marathon.zk-compression}} --zk_compression{{/marathon.zk-compression}}{{^marathon.zk-compression}}--disable_zk_compression{{/marathon.zk-compression}} {{#marathon.zk-compression-threshold}}--zk_compression_threshold \"{{marathon.zk-compression-threshold}}\"{{/marathon.zk-compression-threshold}} {{#marathon.zk-connection-timeout}}--zk_connection_timeout \"{{marathon.zk-connection-timeout}}\"{{/marathon.zk-connection-timeout}} {{#marathon.zk-max-node-size}}--zk_max_node_size \"{{marathon.zk-max-node-size}}\"{{/marathon.zk-max-node-size}} {{#marathon.zk-max-versions}}--zk_max_versions \"{{marathon.zk-max-versions}}\"{{/marathon.zk-max-versions}} {{#marathon.zk-session-timeout}}--zk_session_timeout \"{{marathon.zk-session-timeout}}\"{{/marathon.zk-session-timeout}} {{#marathon.zk-timeout}}--zk_timeout \"{{marathon.zk-timeout}}\"{{/marathon.zk-timeout}}",
Expand Down

0 comments on commit 43930fc

Please sign in to comment.