# consulkv **Repository Path**: single_yang/consulkv ## Basic Information - **Project Name**: consulkv - **Description**: to get consul kv , base python-consul - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-11-25 - **Last Updated**: 2022-06-24 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # consulkv Python 3 client for the consul key/value store. # Installation Install directly from Gitee ``` pip install git+https://gitee.com/single_yang/consulkv.git@master#egg=consulkv ``` # Usage ### Create consul client ```bash conf = consulkv.Config() ``` ### put key ```bash conf.put("key", 'value') conf.put('namespace/key', 'value') return Ture/False ``` ### delete key ```bash conf.delete('key') conf.delete('namespace/key') return Ture/False ``` ### delete all keys in path ```bash conf.delete('path', recurse=True) ``` ### get key ```bash conf.get('key') {key: value} conf.get('key/') {key1: value1, key2: value2, ..., keys: values} ``` # Create Package ```bash git clone https://gitee.com/single_yang/consulkv.git pip3 install wheel pip3 install -r requirements.txt python3 setup.py sdist ```