Commit Graph

40 Commits

Author SHA1 Message Date
zhu.boxiang
de4adde69e feat: Support devstack integrated functional test
1. add skyline-functional-devstack which inherits from devstack
2. add skyline-functional-devstack into check and gate job
3. add playbook to integrate with devstack for zuul
4. change the port from 8080 to 9999 because the 8080 is used for s3api
5. rename functional-py38 as unittest-py38
6. add install extra tools ready for skyline-console's e2e test

Change-Id: I7f4b549bec6573661e62dd2bd9a3355253afd47d
2021-09-16 13:31:55 +08:00
Zuul
8fd70b6823 Merge "fix: Change the version of setuptools" 2021-09-10 10:27:09 +00:00
zhu.boxiang
809802d920 fix: Change the version of setuptools
The setuptools(>=58.0.0) has removed the support of use_2to3 during build[1].
There is a package named tempita[2] which has set use_2to3 in setup.py.

So here, we set the version of setuptools less than 58.0.0

[1]: https://setuptools.readthedocs.io/en/latest/history.html#v58-0-0
[2]: https://github.com/agramfort/tempita/blob/master/setup.py#L53

Change-Id: I0fffaa63eb91c4d4c4bf8d7e149e7087e514aa51
2021-09-10 17:56:44 +08:00
zhu.boxiang
cfba942e3c fix: Remove git_config when make venv
Remove git_config when make venv. So when we integrate
with devstack, we will not be interrupted by git.

Change-Id: I23d6fac4dda5bc1c2caa269f0591cb4e6137743d
2021-09-10 15:31:24 +08:00
zhu.boxiang
8faca27477 docs: Update README doc to link devstack README doc
1. Add devstack README doc link to README zh_CN and en doc
2. Update the table of contents

Change-Id: Iff2dae1d87e6f01eb564542e4b3718f9cfba0887
2021-09-09 11:59:01 +08:00
zhu.boxiang
8b288e1955 feat: Support to deploy skyline with devstack
Add devstack plugin for skyline to deploy by devstack.

There are six main functions for this plugin:
1. install_skyline: to install main dependency of environment,
skyline-apiserver and skyline-console
2. configure_skyline: to config skyline.conf for skyline-apiserver
and nginx.conf for nginx
3. init_skyline: create database of skyline and make db sync
4. start_skyline: start skyline-apiserver as systemd and start nginx
5. stop skyline: stop skyline-apiserver and stop nginx
6. cleanup_skyline: remove all config directories

Change-Id: I632f059b26a3d8612fc1008758f1844498ce7b84
2021-09-08 18:16:06 +08:00
Wu Wenxiang
b8be76df8a fix: get domain always from admin interface
Use config interface in keystone client, rather than default value.

Closes-bug: #1940148
Change-Id: Id0cec1e488f854bfd6e2321e6abe9ac6d5f4a486
2021-09-08 16:37:00 +08:00
zhu.boxiang
f5c946e1c6 fix: Double all_projects params
Input double all_projects params when calling list_projects
function. Remove one of them.

Closes-Bug: #1942087
Change-Id: I7cc80dcb497a2996d50770e6c2b29c9779640e85
2021-08-31 16:58:05 +08:00
zhu.boxiang
4abe8d4032 fix: Lack of import constants
Use constants in contrib but lack of import it.
Here we import constants from skyline_apiserver.types to fix it.

Closes-Bug: #1942087
Change-Id: I6fd874400f77e9d201d6c5d7284c78345d52b63f
2021-08-31 11:52:00 +08:00
Zuul
3b3d292cc5 Merge "fix: Fix make build failed" 2021-08-25 09:27:54 +00:00
Zuul
d182e386e9 Merge "feature: Add x-openstack-request-id into header" 2021-08-25 09:21:58 +00:00
Gao Hanxiang
3855a725a9 fix: Fix make build failed
Since poetry 1.1.8 version introduces a large number of bugs[1], which
makes the process of building container image fail, so the 1.1.8
version of poetry is not used.

[1] https://github.com/python-poetry/poetry/issues/4429

Change-Id: Ia30c2c5e783401aa4bad85139b0bf2fa9a822847
2021-08-25 04:54:43 -04:00
shaleijie
08126209de feature: Add ZUUL JOBs
1. Add `skyline-tox-functional-py38` job to execute unit tests
2. Add `skyline-tox-lint-py38` job to execute code static analysis

Change-Id: I6ee8e89e72b3769a2803f8dc2a7b7a434f16e16f
2021-08-25 15:01:17 +08:00
chenliufeiyang
6dfa997a79 feature: Add x-openstack-request-id into header
1. Add x-openstack-request-id into header
Let the skyline API continue to pass down with Request ID using for tracking chain.
It contributes to find the problem preliminarily.

Change-Id: Ib7f7dcc98183aa99a00fc69b73eba53d87642502
2021-08-25 12:47:26 +08:00
Zuul
bea439480a Merge "fix: Re-generate the poetry.lock" 2021-08-23 14:48:33 +00:00
zhu.boxiang
f3ee9d3b8c fix: Re-generate the poetry.lock
The skyline-nginx is dependent on skyline-apiserver.
From the patch[0], we add aiosqlite into tool.poetry.dependencies.
So we need to re-generate the poetry.lock of skyline-nginx.

[0]: https://review.opendev.org/c/skyline/skyline-apiserver/+/803539

Change-Id: I82dc76ed286376d2c388e1dab95d4c24743d02f2
2021-08-23 13:32:45 +08:00
chenliufeiyang
ebf89092fd fix: Fix params' default value of function
1. Do not use mutable types as method parameter defaults

Change-Id: Ie310114f53981451b50a366a0869be72bbfb4e01
2021-08-20 15:11:12 +08:00
Wu Wenxiang
988f38cc41 docs: add mascot description
1. add mascot nine-color-deer description

Change-Id: I492483c3b1223551c42907028d7e0b74bc5441ad
2021-08-05 18:05:11 +08:00
Wu Wenxiang
3a1fab6085 fix: add quick start with sqlite in README doc
1. add quick launch steps for skyline docker image with sqlite

Change-Id: I6c29bdacae09ac5fec40d60b92c57c8786c0aa52
2021-08-05 16:56:04 +08:00
zhu.boxiang
c78ef2f522 fix: Update README doc and fix dependency
Update the develop chapter of README doc.
Also fix the aiosqlite dependency if skyline-apiserver.

Change-Id: Ie769037872dcc64f2f83013869f98028846b242f
2021-08-05 14:31:13 +08:00
Gao Hanxiang
3176cfbc47 fix: 400 page appears when using http protocol to access
When using http protocol to access, nginx will respond with 400 and
report "400 The plain HTTP request was sent to HTTPS port".
The reason is that http 497 error[1] appeared in nginx, so 497
error was redirected to https protocol.

[1] 56f5331683/src/http/ngx_http_special_response.c (L274)

Change-Id: I01c35318dd5d219dbb31e6a89bdc05d2a4db7804
2021-07-29 05:28:58 +00:00
Gao Hanxiang
acf17c752b fix: Add timeout to keystone session
When a network failure occurs, the openstack client will be blocked for
a long time. Set a timeout on the session to feedback network problem
as soon as possible.

Change-Id: I2eec95b18241b0bf2103ad3dfa1efd2774f2bd77
2021-07-29 01:20:35 -04:00
Zuul
70381b608c Merge "docs: Add quick start docs" 2021-07-29 05:15:20 +00:00
Zuul
791f6f14ac Merge "feat: Add bootstrap support for skyline image" 2021-07-29 05:14:17 +00:00
Gao Hanxiang
8e54a0cc82 docs: Add quick start docs
1. Add a quick start, the document explains how to use the container to
quickly deploy the skyline service.

2. Modify the format of the original `Development skyline-apiserver`
section.

Change-Id: I4ff1c179791b782311be4d8c391565bfcaf16bf9
2021-07-27 05:09:20 +00:00
Gao Hanxiang
a0701711be feat: Add bootstrap support for skyline image
When docker run, specify the KOLLA_BOOSTRAP environment variable, the
skyline image will initialize the database, and if it is not specified,
the skyline service will be run in the normal way.
This provides the basis for subsequent docking with kolla-ansible.

Change-Id: I5eaad038b3ed3c3189f2b41e41c14d28a346ee88
2021-07-26 11:01:31 -04:00
Gao Hanxiang
8d8c8bd89f chore: Add make clean to clean up project directory
1. Add make clean
2. Specify configuration file used by mypy
3. Add some directories to dockerignore

Change-Id: I4f6b0d5ba894214bb0fcff21443f9808f56d595e
2021-07-26 14:35:55 +00:00
Gao Hanxiang
ee84ba0b8f feat: Add make build
1. Add dockerfile
2. Modify gunicorn config

Change-Id: I99d233908b3f21e5e0a4cd739ee7702839a8fb46
2021-07-26 03:51:01 +00:00
Gao Hanxiang
4fa4083d57 refactor: Streamline libs directory structure
1. Adjust makefile
2. Delete unused files

Change-Id: I73a7490e658763b57ef528359ebbde6d945740db
2021-07-26 03:50:00 +00:00
Gao Hanxiang
4935be6f47 refactor: Move skyline-apiserver to libs
1. Move skyline-apiserver to libs
2. Modify Makefile
3. Rename the skyline-apiserver.yaml.sample file to skyline.yaml.sample

At the top level, we use "skyline" as the namespace, using the idea of
monorepo to manage the project. At the top level, only some common
configuration files (mypy.ini, black.conf, isort.conf, etc.) and
common tools are included.

In the `libs` directory, there are three core libraries,
skyline-console, skyline-apiserver, skyline-nginx, and some dependent
libraries.
There are cross-imports between these libraries,
for example: skyline-nginx requires skyline-apiserver;
Both skyline-nginx and skyline-apiserver require skyline-config.

Therefore, skyline-apiserver should not be placed
at the top level, it is also suitable for management as a library.


Change-Id: Ie2f1f4bdfbc2e985ec4327705eecaae3181f5b50
2021-07-26 03:48:54 +00:00
Gao Hanxiang
5e4f40f364 feat: Add skyline-nginx package
1. Add skyline-nginx package for managing and generating nginx
   configuration.

Change-Id: I68afd9ab9ad52fc96c13e745cb1e89a8061a53ba
2021-07-26 03:46:20 +00:00
Gao Hanxiang
dfaf962aca feat: Add skyline-console to submodule
When building a docker image, skyline-console is required,
so add skyline-console as a git submodule.

Change-Id: I429879dbfb93f48aacbe09966388f25a5afab43d
2021-07-19 02:46:39 +00:00
zhu.boxiang
826234e9db feat: Add skyline-config under libs
1. remove base.py under config folder
2. add skyline-config library under libs

Change-Id: I71561bc3f6acbff3d90c9ad1922095e71497f226
2021-07-07 16:14:11 +08:00
Zuul
3b39497ac6 Merge "refactor: Use __version__ instead of VERSION in constants" 2021-07-07 08:10:15 +00:00
zhu.boxiang
a65e543bdf feat: Add make genconfig to generate sample config
1. add a cmd script to generate sample config
2. set setup as False for generate_swagger, so we can make swagger
without skyline-apiserver yaml config
3. add make genconfig into Makefile
4. add config-sample-generator scripts into pyproject.toml
5. replace async with sync for generate_swagger script
6. add items, keys, values function for Group and Configuration

Change-Id: I4c7196f1d766a6abdc24c71c4b3135cd40cc26ef
2021-07-02 10:54:51 +08:00
zhu.boxiang
8eb2825b9b refactor: Use __version__ instead of VERSION in constants
Remove the VERSION from constants. Just use __version__ as
version in profile.

Change-Id: I6128077182e223d708c17753524a1f42dc6fad27
2021-07-01 15:26:43 +08:00
zhu.boxiang
c1bb509391 fix: Add sample yaml config file
Under etc dictory, add sample yaml config file
named skyline-apiserver.yaml.sample
Updated the README.md and README-zh_CN.md file
to make quick start more clearly.

Closes-Bug: #1931673
Change-Id: I023cfbeac33543d2989f5017c878cd17160f8c76
2021-06-16 06:22:14 +00:00
Hanxiang Gao
38ea9e3d59 feat: Add initial code of skyline-apiserver
Add initial code of skyline-apiserver

Change-Id: Ib425960b707237193fd8531fb3989f29282f5b58
2021-06-01 23:39:57 +08:00
Thierry Carrez
f18ff79249 Add Zuul support for new repository
Before adding any code, add basic Zuul support for the repository
(noop-tests) so that it can pass Zuul checks and gating.

Change-Id: Ib728f83fedd08c989c38f02672f700fe133b39f5
2021-05-10 12:47:51 +02:00
OpenDev Project Creator
f941a04712 Added .gitreview 2021-05-08 17:14:30 +00:00