Skip to content
This repository has been archived by the owner on Jul 19, 2021. It is now read-only.

Commit

Permalink
Merge branch 'feature-net-image-params'
Browse files Browse the repository at this point in the history
  • Loading branch information
greyarch committed May 16, 2017
1 parent ce04186 commit a4f312f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions index.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ENABLE_NETWORK_HEALTHCHECK = env.get 'ENABLE_NETWORK_HEALTHCHECK', false
NETWORK_HEALTHCHECK_TEST_INTERFACE = env.get 'NETWORK_HEALTHCHECK_TEST_INTERFACE', 'eth0'
NETWORK_HEALTHCHECK_TEST_IP_PREFIX = env.get 'NETWORK_HEALTHCHECK_TEST_IP_PREFIX', '10.25'

pipeworksCmd = env.get 'PIPEWORKS_CMD', 'eth1 -i eth0 @CONTAINER_NAME@ dhclient @3055'
pipeworksCmd = env.get 'PIPEWORKS_CMD', 'eth1 -i eth0 @CONTAINER_NAME@ 0/0 @3055'
vlan = parseInt(pipeworksCmd.slice(-4)) - 3000
scanCmd = env.get 'NETWORK_SCAN_CMD', "nmap -sP -n 10.25.#{vlan}.51-240"

Expand All @@ -35,7 +35,7 @@ config =
scanInterval: parseInt(env.get 'DHCP_SCAN_INTERVAL', '5000')
scanEnabled: env.get 'DHCP_SCAN_ENABLED', 'true'
net_container:
image: env.get 'NETWORK_IMAGE', 'ictu/pipes:1'
image: env.get 'NETWORK_IMAGE', 'ictu/pipes:2'
pipeworksCmd: pipeworksCmd
startcheck:
test: "ifconfig #{NETWORK_HEALTHCHECK_TEST_INTERFACE} | grep inet | grep #{NETWORK_HEALTHCHECK_TEST_IP_PREFIX}"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "docker-dashboard-agent-compose",
"version": "2.11.0",
"version": "3.0.0",
"description": "",
"main": "index.js",
"scripts": {
Expand Down
8 changes: 4 additions & 4 deletions tests/coffee/compose.test.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ compose = require '../../src/coffee/compose.coffee'

standardCfg =
net_container:
image: 'ictu/pipes:1'
pipeworksCmd: 'eth12 -i eth0 @CONTAINER_NAME@ dhclient @1234'
image: 'ictu/pipes:2'
pipeworksCmd: 'eth12 -i eth0 @CONTAINER_NAME@ 0/0 @1234'

describe 'Compose', ->
describe 'augmentCompose', ->
Expand Down Expand Up @@ -171,8 +171,8 @@ describe 'Compose', ->
assert.equal service.network_mode, 'service:bb-net-service1'
assert.deepEqual service.depends_on, 'bb-net-service1': condition: 'service_started'
assert.deepEqual doc.services['bb-net-service1'],
image: 'ictu/pipes:1'
environment: eth0_pipework_cmd: "eth12 -i eth0 @CONTAINER_NAME@ dhclient @1234"
image: 'ictu/pipes:2'
environment: eth0_pipework_cmd: "eth12 -i eth0 @CONTAINER_NAME@ 0/0 @1234"
hostname: 'service1.instance2.google.com'
dns_search: 'instance2.google.com'
network_mode: 'none'
Expand Down

0 comments on commit a4f312f

Please sign in to comment.