Beispiel #1
0
 def test_graphite_config_options(self):
     self._set_config_file('graphite_configured.conf')
     config = Config()
     self.assertEqual(config.NEXUS_USER, None)
     self.assertEqual(config.NEXUS_HOST, None)
     self.assertEqual(config.NEXUS_PORT, 0)
     self.assertEqual(config.NEXUS_REPOSITORY, None)
     self.assertEqual(config.GRAPHITE_HOST, 'graphite.int.mycompany.com')
Beispiel #2
0
 def test_no_config_file(self):
     self._set_config_file('does_not_exist.conf')
     config = Config()
     self.assertEqual(config.NEXUS_USER, None)
     self.assertEqual(config.NEXUS_USER, None)
     self.assertEqual(config.NEXUS_PORT, 0)
     self.assertEqual(config.NEXUS_REPOSITORY, None)
     self.assertEqual(config.GRAPHITE_HOST, None)
Beispiel #3
0
 def test_nexus_config_options(self):
     self._set_config_file('nexus_configured.conf')
     config = Config()
     self.assertEqual(config.NEXUS_USER, 'username')
     self.assertEqual(config.NEXUS_HOST, 'mynexushost.int.mycompany.com')
     self.assertEqual(config.NEXUS_PORT, 8080)
     self.assertEqual(config.NEXUS_REPOSITORY, 'releases')
     self.assertEqual(config.GRAPHITE_HOST, None)
Beispiel #4
0
 def test_track_event_endpoint_options(self):
     self._set_config_file('track_event_configured.conf')
     config = Config()
     self.assertEqual(config.NEXUS_USER, None)
     self.assertEqual(config.NEXUS_HOST, None)
     self.assertEqual(config.NEXUS_PORT, 0)
     self.assertEqual(config.NEXUS_REPOSITORY, None)
     self.assertEqual(config.GRAPHITE_HOST, None)
     self.assertEqual(config.TRACK_EVENT_ENDPOINT, 'api.int.mycompany.com/track/')
Beispiel #5
0
import urllib2

import requests
from debian import deb822

from fabric.colors import red, green, magenta, blue
from fabric.context_managers import cd, lcd, hide
from fabric.contrib import files
from fabric.operations import sudo, local, run, prompt, put
from fabric.state import env
from fabric.tasks import WrappedCallableTask

from mendel.conf import Config
from mendel.util import lcd_task

config = Config()

if getattr(env, '_already_built', None) is None:
    env._already_built = False

###############################################################################
# TODO - add example services in python, demonstrate crons can
# also work
# TODO - add vagrant box with examples
# TODO drop a file into release directories that are "successful"
# TODO so we don't roll back to a failed build. either that or we cleanup after
# TODO ourselves

# TODO remote_deb will replace deb as soon as we can get all those services
# TODO using `deb` migrated into nexus. For now we need to support both though
###############################################################################