#!/usr/bin/env python
# -*- coding: utf-8 -*-

import os
import sys

from fabric.api import env
from fabric.api import run

BASE_DIR = os.path.dirname(os.path.dirname(__file__))
BASE_DIR = os.path.realpath(BASE_DIR)
sys.path.append(BASE_DIR)
sys.path.append(os.path.join(BASE_DIR, '..'))

from utils.utils import logger, DeployBaseTask


class DeployTask(DeployBaseTask):
    PROJECT_PATH = '/home/ordergroup/sites/popojutrze'
    VIRTUALENV_ACTIVATE = 'source /home/ordergroup/venvs/popojutrze/bin/activate'


class DeployDevTask(DeployTask):
    name = 'dev_dep'

    def run(self, branch='dev_dep', db_env='dev_dep', install_req=False):
        self.set_host('dev.ordergroup.pl')
        super(DeployDevTask, self).run(branch, db_env, install_req)


deployDev = DeployDevTask()
