diff options
| -rw-r--r-- | .gitignore | 1 | ||||
| -rw-r--r-- | python-nifcloud.spec | 280 | ||||
| -rw-r--r-- | sources | 1 |
3 files changed, 282 insertions, 0 deletions
@@ -0,0 +1 @@ +/nifcloud-1.6.0.tar.gz diff --git a/python-nifcloud.spec b/python-nifcloud.spec new file mode 100644 index 0000000..9b5bbca --- /dev/null +++ b/python-nifcloud.spec @@ -0,0 +1,280 @@ +%global _empty_manifest_terminate_build 0 +Name: python-nifcloud +Version: 1.6.0 +Release: 1 +Summary: Data-driven NIFCLOUD SDK for Python +License: Apache License 2.0 +URL: https://github.com/nifcloud/nifcloud-sdk-python +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/52/93/008fcdfe78ca4031286acc1b0e5a33e169a47b48a5eb13c51ea7efc2c9d7/nifcloud-1.6.0.tar.gz +BuildArch: noarch + +Requires: python3-botocore + +%description +# NIFCLOUD SDK for Python + +[](https://github.com/nifcloud/nifcloud-sdk-python/actions?query=workflow%3ATest) +[](https://nifcloud-sdk-python.readthedocs.io/en/latest/) +[](https://pypi.python.org/pypi/nifcloud) + +The **NIFCLOUD SDK for Python** is data-driven SDK. +It works by feeding AWS-SDK-compatible model JSONs to botocore module. + +## Features + +* :heavy_check_mark: Full support for NIFCLOUD Computing / RDB / NAS / Script / Hatoba / ESS / DNS / ObjectStorageService / ServiceActivity APIs +* :heavy_check_mark: The nifcloud package is the foundation for the [NIFCLOUD CLI](https://github.com/nifcloud/nifcloud-cli). +* :heavy_check_mark: AWS-SDK-compatible data-driven architecture + +## Requirements + +* Python 2.6 or later + +## How to Install + +``` +pip install nifcloud +``` + +## Usage + +Write your python program: + +```python +from nifcloud import session + +client = session.get_session().create_client( + "computing", + region_name="jp-east-1", + nifcloud_access_key_id="<Your NIFCLOUD Access Key ID>", + nifcloud_secret_access_key="<Your NIFCLOUD Secret Access Key>" +) + +print(client.describe_instances()) +``` + +Execute the program: + +``` +$ python test.py +``` + +Credentials and region name can be also passed via environment variables. + +```python +from nifcloud import session + +client = session.get_session().create_client("computing") +print(client.describe_instances()) +``` + +``` +$ export NIFCLOUD_ACCESS_KEY_ID=<Your NIFCLOUD Access Key ID> +$ export NIFCLOUD_SECRET_ACCESS_KEY=<Your NIFCLOUD Secret Access Key> +$ export NIFCLOUD_DEFAULT_REGION=jp-east-1 +$ python test.py +``` + +See [documentation](https://nifcloud-sdk-python.readthedocs.io/en/latest/) for detail. + +## License + +See [LICENSE.txt](LICENSE.txt). + + +%package -n python3-nifcloud +Summary: Data-driven NIFCLOUD SDK for Python +Provides: python-nifcloud +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-nifcloud +# NIFCLOUD SDK for Python + +[](https://github.com/nifcloud/nifcloud-sdk-python/actions?query=workflow%3ATest) +[](https://nifcloud-sdk-python.readthedocs.io/en/latest/) +[](https://pypi.python.org/pypi/nifcloud) + +The **NIFCLOUD SDK for Python** is data-driven SDK. +It works by feeding AWS-SDK-compatible model JSONs to botocore module. + +## Features + +* :heavy_check_mark: Full support for NIFCLOUD Computing / RDB / NAS / Script / Hatoba / ESS / DNS / ObjectStorageService / ServiceActivity APIs +* :heavy_check_mark: The nifcloud package is the foundation for the [NIFCLOUD CLI](https://github.com/nifcloud/nifcloud-cli). +* :heavy_check_mark: AWS-SDK-compatible data-driven architecture + +## Requirements + +* Python 2.6 or later + +## How to Install + +``` +pip install nifcloud +``` + +## Usage + +Write your python program: + +```python +from nifcloud import session + +client = session.get_session().create_client( + "computing", + region_name="jp-east-1", + nifcloud_access_key_id="<Your NIFCLOUD Access Key ID>", + nifcloud_secret_access_key="<Your NIFCLOUD Secret Access Key>" +) + +print(client.describe_instances()) +``` + +Execute the program: + +``` +$ python test.py +``` + +Credentials and region name can be also passed via environment variables. + +```python +from nifcloud import session + +client = session.get_session().create_client("computing") +print(client.describe_instances()) +``` + +``` +$ export NIFCLOUD_ACCESS_KEY_ID=<Your NIFCLOUD Access Key ID> +$ export NIFCLOUD_SECRET_ACCESS_KEY=<Your NIFCLOUD Secret Access Key> +$ export NIFCLOUD_DEFAULT_REGION=jp-east-1 +$ python test.py +``` + +See [documentation](https://nifcloud-sdk-python.readthedocs.io/en/latest/) for detail. + +## License + +See [LICENSE.txt](LICENSE.txt). + + +%package help +Summary: Development documents and examples for nifcloud +Provides: python3-nifcloud-doc +%description help +# NIFCLOUD SDK for Python + +[](https://github.com/nifcloud/nifcloud-sdk-python/actions?query=workflow%3ATest) +[](https://nifcloud-sdk-python.readthedocs.io/en/latest/) +[](https://pypi.python.org/pypi/nifcloud) + +The **NIFCLOUD SDK for Python** is data-driven SDK. +It works by feeding AWS-SDK-compatible model JSONs to botocore module. + +## Features + +* :heavy_check_mark: Full support for NIFCLOUD Computing / RDB / NAS / Script / Hatoba / ESS / DNS / ObjectStorageService / ServiceActivity APIs +* :heavy_check_mark: The nifcloud package is the foundation for the [NIFCLOUD CLI](https://github.com/nifcloud/nifcloud-cli). +* :heavy_check_mark: AWS-SDK-compatible data-driven architecture + +## Requirements + +* Python 2.6 or later + +## How to Install + +``` +pip install nifcloud +``` + +## Usage + +Write your python program: + +```python +from nifcloud import session + +client = session.get_session().create_client( + "computing", + region_name="jp-east-1", + nifcloud_access_key_id="<Your NIFCLOUD Access Key ID>", + nifcloud_secret_access_key="<Your NIFCLOUD Secret Access Key>" +) + +print(client.describe_instances()) +``` + +Execute the program: + +``` +$ python test.py +``` + +Credentials and region name can be also passed via environment variables. + +```python +from nifcloud import session + +client = session.get_session().create_client("computing") +print(client.describe_instances()) +``` + +``` +$ export NIFCLOUD_ACCESS_KEY_ID=<Your NIFCLOUD Access Key ID> +$ export NIFCLOUD_SECRET_ACCESS_KEY=<Your NIFCLOUD Secret Access Key> +$ export NIFCLOUD_DEFAULT_REGION=jp-east-1 +$ python test.py +``` + +See [documentation](https://nifcloud-sdk-python.readthedocs.io/en/latest/) for detail. + +## License + +See [LICENSE.txt](LICENSE.txt). + + +%prep +%autosetup -n nifcloud-1.6.0 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-nifcloud -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Wed May 17 2023 Python_Bot <Python_Bot@openeuler.org> - 1.6.0-1 +- Package Spec generated @@ -0,0 +1 @@ +9cdf37d4b15acf1f1def50b2437a3e87 nifcloud-1.6.0.tar.gz |
