관리-도구
편집 파일: apps_manager.cpython-37.pyc
B �v6d�Q � @ s d dl mZ d dl mZ d dl mZ d dlZd dlZd dlZd dlZd dlm Z m Z d dlmZ d dl Z d dlmZmZ d dlmZ d d lmZmZmZ d d lmZ d dlmZmZmZ d dlmZ d d lm Z G dd� de!�Z"G dd� de!�Z#G dd� de�Z$ddd�Z%dS )� )�print_function)�division)�absolute_importN)�AnyStr�Optional)� iteritems)�get_abs_rel�run_process_in_cagefs)�drop_privileges)�BaseSelectorError�MissingVirtualenvError�MissingAppRootError)� WSGI_PATH)�ClSelectExcept�clpassenger�clselectctl)�BaseApplicationsManager)� PythonManagerc @ s e Zd ZdZdZdZdS )�PythonAppFormatVersionz@ Class represents possible python application versions. � � N)�__name__� __module__�__qualname__�__doc__�LEGACY�STABLE� r r �U/opt/alt/python37/lib/python3.7/site-packages/clselect/clselectpython/apps_manager.pyr # s r c @ s e Zd ZdZdZdZdS )�PythonVenvFormatVersionzJ Class represents possible python application venv path versions. r r N)r r r r r r r r r r r . s r c s� e Zd ZdZdZdZdZdZdZdZ dZ � fdd �Zd-� fdd� Ze d d� �Zdd� Zdd� Zd.dd�Zd/dd�Zdd� Zdd� Zdd� Zdd� Zd0d d!�Zd"d#� Zd1� fd$d%� Zd&d'� Zd2d)d*�Zd3d+d,�Z� ZS )4�ApplicationsManagerz!.cl.selector/python-selector.jsonz/var/lve/.py.migration.statusz!.cl.selector/.py.migration.statusz//var/log/cloudlinux/py-selector/app_imports.logzimported_pip_requirements.txt�python� virtualenvc s t t| ��t� � d S )N)�superr �__init__r )�self)� __class__r r r$ D s zApplicationsManager.__init__r c s t t| �j|||d�S )N)�patterns)r# r �_find_config_files)r% � user_name� app_directoryr'