diff options
| author | CoprDistGit <infra@openeuler.org> | 2023-05-05 06:33:25 +0000 |
|---|---|---|
| committer | CoprDistGit <infra@openeuler.org> | 2023-05-05 06:33:25 +0000 |
| commit | a448e21eb48229a6a1cfb3410f67c48edcb3649f (patch) | |
| tree | 3ccf4d6437989005b2783dc37df908d21d55ebeb /python-argo-models.spec | |
| parent | c1b71a1eb0e04d6845be9b671ed7088dcb37526d (diff) | |
automatic import of python-argo-modelsopeneuler20.03
Diffstat (limited to 'python-argo-models.spec')
| -rw-r--r-- | python-argo-models.spec | 237 |
1 files changed, 237 insertions, 0 deletions
diff --git a/python-argo-models.spec b/python-argo-models.spec new file mode 100644 index 0000000..3f48a6f --- /dev/null +++ b/python-argo-models.spec @@ -0,0 +1,237 @@ +%global _empty_manifest_terminate_build 0 +Name: python-argo-models +Version: 2.7.5 +Release: 1 +Summary: Generated openapi models for Argo objects. +License: Apache Software License +URL: https://github.com/e2fyi/argo-models +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/9e/a8/a9d67f55bbe862cdbf08bbf8dc0e9805f070796e005ad103e9e54959df40/argo-models-2.7.5.tar.gz +BuildArch: noarch + + +%description +# argo-models + +[](https://travis-ci.org/e2fyi/argo-models) +[](https://badge.fury.io/py/argo-models) +[](https://pepy.tech/project/argo-models/month) + +`argo-models` is a `argo` namespaced package with the `argo.models` subpackage +which contains the generated OpenAPI models from [Argo](https://github.com/argoproj/argo). + +Documentations can be found at https://argo-models.readthedocs.io/en/latest/ + +```bash +pip install argo-models +``` + +```py +from argo.models import V1alpha1ArtifactLocation, V1alpha1S3Artifact +from kubernetes.client.models import V1SecretKeySelector + +# create aws cred +access_key_secret = V1SecretKeySelector(name="s3_secret", key="accesskey") +secret_key_secret = V1SecretKeySelector(name="s3_secret", key="secretkey") + +# create artifact config for s3 +s3_artifact = V1alpha1S3Artifact( + bucket="foobar", + endpoint="s3.amazonaws.com" + insecure=False, + access_key_secret=access_key_secret, + secret_key_secret=secret_key_secret, + key="" +) + +# create artifact location +artifact_location = V1alpha1ArtifactLocation(s3=s3_artifact) + +``` + +## Developer notes + +To generate the latest models, update `version.txt` with the desired argo release +(e.g. `2.3.0-rc3`) and then run `./generate-api.sh`. + +To release new version to pypi, create a release with the corresponding version tag (e.g. `v2.2.1`). Travis will automatically publish the package. + +> NOTE: +> +> `version.txt` should hold the current/latest argo version to be generated, as it +> is also used by `setup.py` as the `argo-models` package version. +> +> Please install [@openapitools/openapi-generator-cli](https://www.npmjs.com/package/@openapitools/openapi-generator-cli) to +> generate the openapi specs. + +## License + +This package is licensed under [Apache-2.0](./LICENSE) and is a derivative of the [Argo project](https://github.com/argoproj/argo) using [OpenAPI generator](https://github.com/OpenAPITools/openapi-generator). + +%package -n python3-argo-models +Summary: Generated openapi models for Argo objects. +Provides: python-argo-models +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-argo-models +# argo-models + +[](https://travis-ci.org/e2fyi/argo-models) +[](https://badge.fury.io/py/argo-models) +[](https://pepy.tech/project/argo-models/month) + +`argo-models` is a `argo` namespaced package with the `argo.models` subpackage +which contains the generated OpenAPI models from [Argo](https://github.com/argoproj/argo). + +Documentations can be found at https://argo-models.readthedocs.io/en/latest/ + +```bash +pip install argo-models +``` + +```py +from argo.models import V1alpha1ArtifactLocation, V1alpha1S3Artifact +from kubernetes.client.models import V1SecretKeySelector + +# create aws cred +access_key_secret = V1SecretKeySelector(name="s3_secret", key="accesskey") +secret_key_secret = V1SecretKeySelector(name="s3_secret", key="secretkey") + +# create artifact config for s3 +s3_artifact = V1alpha1S3Artifact( + bucket="foobar", + endpoint="s3.amazonaws.com" + insecure=False, + access_key_secret=access_key_secret, + secret_key_secret=secret_key_secret, + key="" +) + +# create artifact location +artifact_location = V1alpha1ArtifactLocation(s3=s3_artifact) + +``` + +## Developer notes + +To generate the latest models, update `version.txt` with the desired argo release +(e.g. `2.3.0-rc3`) and then run `./generate-api.sh`. + +To release new version to pypi, create a release with the corresponding version tag (e.g. `v2.2.1`). Travis will automatically publish the package. + +> NOTE: +> +> `version.txt` should hold the current/latest argo version to be generated, as it +> is also used by `setup.py` as the `argo-models` package version. +> +> Please install [@openapitools/openapi-generator-cli](https://www.npmjs.com/package/@openapitools/openapi-generator-cli) to +> generate the openapi specs. + +## License + +This package is licensed under [Apache-2.0](./LICENSE) and is a derivative of the [Argo project](https://github.com/argoproj/argo) using [OpenAPI generator](https://github.com/OpenAPITools/openapi-generator). + +%package help +Summary: Development documents and examples for argo-models +Provides: python3-argo-models-doc +%description help +# argo-models + +[](https://travis-ci.org/e2fyi/argo-models) +[](https://badge.fury.io/py/argo-models) +[](https://pepy.tech/project/argo-models/month) + +`argo-models` is a `argo` namespaced package with the `argo.models` subpackage +which contains the generated OpenAPI models from [Argo](https://github.com/argoproj/argo). + +Documentations can be found at https://argo-models.readthedocs.io/en/latest/ + +```bash +pip install argo-models +``` + +```py +from argo.models import V1alpha1ArtifactLocation, V1alpha1S3Artifact +from kubernetes.client.models import V1SecretKeySelector + +# create aws cred +access_key_secret = V1SecretKeySelector(name="s3_secret", key="accesskey") +secret_key_secret = V1SecretKeySelector(name="s3_secret", key="secretkey") + +# create artifact config for s3 +s3_artifact = V1alpha1S3Artifact( + bucket="foobar", + endpoint="s3.amazonaws.com" + insecure=False, + access_key_secret=access_key_secret, + secret_key_secret=secret_key_secret, + key="" +) + +# create artifact location +artifact_location = V1alpha1ArtifactLocation(s3=s3_artifact) + +``` + +## Developer notes + +To generate the latest models, update `version.txt` with the desired argo release +(e.g. `2.3.0-rc3`) and then run `./generate-api.sh`. + +To release new version to pypi, create a release with the corresponding version tag (e.g. `v2.2.1`). Travis will automatically publish the package. + +> NOTE: +> +> `version.txt` should hold the current/latest argo version to be generated, as it +> is also used by `setup.py` as the `argo-models` package version. +> +> Please install [@openapitools/openapi-generator-cli](https://www.npmjs.com/package/@openapitools/openapi-generator-cli) to +> generate the openapi specs. + +## License + +This package is licensed under [Apache-2.0](./LICENSE) and is a derivative of the [Argo project](https://github.com/argoproj/argo) using [OpenAPI generator](https://github.com/OpenAPITools/openapi-generator). + +%prep +%autosetup -n argo-models-2.7.5 + +%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-argo-models -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Fri May 05 2023 Python_Bot <Python_Bot@openeuler.org> - 2.7.5-1 +- Package Spec generated |
