-
Notifications
You must be signed in to change notification settings - Fork 4.9k
docs(DEVELOPER.md): update to catch up the current behavior #14478
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,7 +62,9 @@ starting point. It contains the proper file structures, configuration files, | |
and CI setup to get up and running quickly. This repository seamlessly | ||
integrates with [Pongo](https://github.com/Kong/kong-pongo). | ||
|
||
## Build and Install from source | ||
## General guide for development | ||
|
||
### Prepare development dependencies and build from source | ||
|
||
This is the hard way to build a development environment, and also a good start | ||
for beginners to understand how everything fits together. | ||
|
@@ -72,7 +74,7 @@ requires some additional third-party dependencies, some of which are compiled | |
with tweaked options, and kong runs on a modified version of OpenResty with | ||
patches. | ||
|
||
To install from the source, first, we clone the repository: | ||
To build from the source, first, we clone the repository: | ||
|
||
```shell | ||
git clone https://github.com/Kong/kong | ||
|
@@ -180,8 +182,8 @@ git config --local url.'ssh://[email protected]/'.insteadOf 'https://github.com/' | |
Finally, we start the build process: | ||
|
||
``` | ||
# Setup virtual environment, download dependencies and install Kong from source | ||
make install | ||
# Setup virtual environment, download dependencies and build Kong from source | ||
make dev | ||
``` | ||
|
||
[The build guide](https://github.com/Kong/kong/blob/master/build/README.md) contains a troubleshooting section if | ||
|
@@ -219,8 +221,6 @@ kong stop | |
deactivate | ||
``` | ||
|
||
### Install Development Dependencies | ||
|
||
#### Running for development | ||
|
||
By default, the development environment adds current directory to Lua files search path. | ||
|
@@ -230,17 +230,14 @@ and [`lua_package_cpath`](https://github.com/openresty/lua-nginx-module#lua_pack | |
directives will allow Kong to find your custom plugin's source code wherever it | ||
might be in your system. | ||
|
||
#### Tests | ||
### Tests | ||
|
||
Install the development dependencies ([busted](https://lunarmodules.github.io/busted/), | ||
[luacheck](https://github.com/mpeterv/luacheck)) with: | ||
Before running any tests, please ensure the development dependencies are installed via | ||
|
||
```shell | ||
make dev | ||
``` | ||
|
||
If Rust/Cargo doesn't work, try setting `export KONG_TEST_USER_CARGO_DISABLED=1` first. | ||
|
||
Kong relies on three test suites using the [busted](https://lunarmodules.github.io/busted/) testing library: | ||
|
||
* Unit tests | ||
|
@@ -355,7 +352,7 @@ are available in both versions (i.e. from helpers.lua). The module | |
the new version into the container of the old version and it can be | ||
used to make new library functionality available to migration tests. | ||
|
||
#### Makefile | ||
### Makefile | ||
|
||
When developing, you can use the `Makefile` for doing the following operations: | ||
|
||
|
Original file line number | Diff line number | Diff line change | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
|
@@ -122,7 +122,7 @@ install-dev-rocks: build-venv | |||||||||
fi \ | ||||||||||
done; | ||||||||||
|
||||||||||
dev: install-rust-toolchain build-venv install-dev-rocks bin/grpcurl bin/h2client | ||||||||||
dev: install-rust-toolchain build-venv build-openresty install-dev-rocks bin/grpcurl bin/h2client | ||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
This fixed the CI failures. Did the missing ![]() BackgroundThe target In simple words, the Makefile target invokes the Bazel target kong/build/openresty/BUILD.openresty.bazel Line 369 in 5885ea4
The Bazel working directory is not cached across the CI jobs, only the Bazel output directory is cached, so the Makefile target There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
The The Makefile task There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I didn't fully deep dive it. There are some hacks inside the And for the full build, at least, it doesn't re-run the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Thanks for your notification. Now I know why: Line 100 in 5885ea4
the |
||||||||||
|
||||||||||
build-release: check-bazel | ||||||||||
$(BAZEL) clean --expunge | ||||||||||
|
Uh oh!
There was an error while loading. Please reload this page.