Skip to content

Commit 733d4f3

Browse files
authored
Update documents. (#56)
1 parent 3fc5147 commit 733d4f3

5 files changed

Lines changed: 83 additions & 51 deletions

File tree

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# INI Settings
2+
3+
This is the configuration list supported in `php.ini`.
4+
5+
| Configuration Item | Description | Default Value |
6+
| ------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------ | ------------------------- |
7+
| skywalking_agent.enable | Enable skywalking_agent extension or not. | Off |
8+
| skywalking_agent.log_file | Log file path. | /tmp/skywalking-agent.log |
9+
| skywalking_agent.log_level | Log level: one of `OFF`, `TRACE`, `DEBUG`, `INFO`, `WARN`, `ERROR`. | INFO |
10+
| skywalking_agent.runtime_dir | Skywalking agent runtime directory. | /tmp/skywalking-agent |
11+
| skywalking_agent.server_addr | Address of skywalking oap server. | 127.0.0.1:11800 |
12+
| skywalking_agent.service_name | Application service name. | hello-skywalking |
13+
| skywalking_agent.skywalking_version | Skywalking version, 8 or 9. | 8 |
14+
| skywalking_agent.authentication | Skywalking authentication token, let it empty if the backend isn't enabled. | |
15+
| skywalking_agent.worker_threads | Skywalking worker threads, 0 will auto set as the cpu core size. | 0 |
16+
| skywalking_agent.enable_tls | Wether to enable tls for gPRC, default is false. | Off |
17+
| skywalking_agent.ssl_trusted_ca_path | The gRPC SSL trusted ca file. | |
18+
| skywalking_agent.ssl_key_path | The private key file. Enable mTLS when `ssl_key_path` and `ssl_cert_chain_path` exist. | |
19+
| skywalking_agent.ssl_cert_chain_path | The certificate file. Enable mTLS when `ssl_key_path` and `ssl_cert_chain_path` exist. | |
20+
| skywalking_agent.heartbeat_period | Agent heartbeat report period. Unit, second. | 30 |
21+
| skywalking_agent.properties_report_period_factor | The agent sends the instance properties to the backend every heartbeat_period * properties_report_period_factor seconds. | 10 |

docs/en/contribution/release-agent.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ your package.
4848
> export RELEASE_VERSION=x.y.z
4949

5050
## The package should be signed by your Apache committer mail.
51-
> gpg --armor --detach-sig skywalking_agent-{$RELEASE_VERSION}.tgz
51+
> gpg --armor --detach-sig skywalking_agent-$RELEASE_VERSION.tgz
5252

53-
> shasum -a 512 skywalking_agent-{$RELEASE_VERSION}.tgz > skywalking_agent-{$RELEASE_VERSION}.tgz.sha512
53+
> shasum -a 512 skywalking_agent-$RELEASE_VERSION.tgz > skywalking_agent-$RELEASE_VERSION.tgz.sha512
5454
```
5555

5656
After these, the source tar with its signed asc and sha512 are ready.
@@ -66,7 +66,7 @@ After these, the source tar with its signed asc and sha512 are ready.
6666
Call a vote in `dev@skywalking.apache.org`
6767

6868
```
69-
Mail title: [VOTE] Release Apache SkyWalking version PHP x.y.z
69+
Mail title: [VOTE] Release Apache SkyWalking PHP version x.y.z
7070
7171
Mail content:
7272
Hi All,

docs/en/setup/service-agent/php-agent/README.md

Lines changed: 49 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -13,34 +13,66 @@
1313
- Make
1414
- Protoc
1515

16-
For Debian-base OS:
16+
## Install dependencies
17+
18+
### For Debian-base OS
1719

1820
```shell
19-
sudo apt install gcc make llvm-dev libclang-dev clang protobuf-compiler
21+
sudo apt install gcc make llvm-13-dev libclang-13-dev protobuf-c-compiler
2022
```
2123

22-
### Install Rust globally
23-
24-
*Refer to <https://forge.rust-lang.org/infra/other-installation-methods.html#standalone-installers>.*
25-
26-
For linux x86_64 user:
24+
### For Alpine Linux
2725

2826
```shell
29-
wget https://static.rust-lang.org/dist/rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
30-
tar zxvf rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
31-
cd rust-1.65.0-x86_64-unknown-linux-gnu
32-
./install.sh
27+
apk add gcc make musl-dev llvm15-dev clang15-dev protobuf-c-compiler
3328
```
3429

30+
## Install Rust globally
31+
32+
The officially recommended way to install Rust is via [`rustup`](https://www.rust-lang.org/tools/install).
33+
34+
But because the source code toolchain is override by `rust-toolchain.toml`,
35+
so if you don't need multi version Rust, we recommend to install Rust by these
36+
way:
37+
38+
1. Install through OS package manager (The Rust version in the source must be >= 1.65).
39+
40+
2. Through [standalone installers](https://forge.rust-lang.org/infra/other-installation-methods.html#standalone-installers).
41+
42+
For linux x86_64 user:
43+
44+
```shell
45+
wget https://static.rust-lang.org/dist/rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
46+
tar zxvf rust-1.65.0-x86_64-unknown-linux-gnu.tar.gz
47+
cd rust-1.65.0-x86_64-unknown-linux-gnu
48+
./install.sh
49+
```
50+
51+
3. Through `rustup` but set `default-toolchain` to none.
52+
53+
```shell
54+
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain none
55+
```
56+
3557
## Install
3658

59+
> If you compile `skywalking_agent` in Alpine Linux, you have to disable `crt-static`, otherwise
60+
> the problem will be throw: "the libclang shared library at /usr/lib/libclang.so.15.0.7 could not
61+
> be opened: Dynamic loading not supported".
62+
>
63+
> You can disable `crt-static` by environment variable:
64+
>
65+
> ```shell
66+
> export RUSTFLAGS="-C target-feature=-crt-static"
67+
> ```
68+
3769
### Install from pecl.net
3870
3971
```shell script
4072
pecl install skywalking_agent
4173
```
4274
43-
### install from the source codes
75+
### Install from the source codes
4476

4577
```shell script
4678
git clone --recursive https://github.com/apache/skywalking-php.git
@@ -52,7 +84,9 @@ make
5284
make install
5385
```
5486

55-
## Configure php.ini
87+
## Configure
88+
89+
Configure skywalking agent in your `php.ini`.
5690

5791
```ini
5892
[skywalking_agent]
@@ -72,35 +106,6 @@ skywalking_agent.server_addr = 127.0.0.1:11800
72106

73107
; Application service name.
74108
skywalking_agent.service_name = hello-skywalking
75-
76-
; Skywalking version.
77-
skywalking_agent.skywalking_version = 8
78-
79-
; Skywalking authentication token, let it empty if the backend isn't enabled.
80-
; skywalking_agent.authentication =
81-
82-
; Skywalking worker threads, 0 will auto set as the cpu core size, default is 0.
83-
; skywalking_agent.worker_threads = 3
84-
85-
; Skywalking agent runtime directory, default is /tmp/skywalking-agent.
86-
; skywalking_agent.runtime_dir = /tmp/skywalking-agent
87-
88-
; Wether to enable tls for gPRC, default is false.
89-
; skywalking_agent.enable_tls = Off
90-
91-
; The gRPC SSL trusted ca file.
92-
; skywalking_agent.ssl_trusted_ca_path =
93-
94-
; The private key file. Enable mTLS when ssl_key_path and ssl_cert_chain_path exist.
95-
; skywalking_agent.ssl_key_path =
96-
97-
; The certificate file. Enable mTLS when ssl_key_path and ssl_cert_chain_path exist.
98-
; skywalking_agent.ssl_cert_chain_path =
99-
100-
; Agent heartbeat report period. Unit, second. Default is 30.
101-
; skywalking_agent.heartbeat_period = 30
102-
103-
; The agent sends the instance properties to the backend every
104-
; heartbeat_period * properties_report_period_factor seconds. Default is 10.
105-
; skywalking_agent.properties_report_period_factor = 10
106109
```
110+
111+
Refer to the Configuration section for more configuration items.

docs/en/setup/service-agent/php-agent/Supported-list.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ The following plugins provide the distributed tracing capability.
77
* PHP-FPM
88
* CLI under [Swoole](https://www.swoole.com/)
99

10-
## Support PHP extension
10+
## Supported PHP extension
1111

1212
* [cURL](https://www.php.net/manual/en/book.curl.php#book.curl)
1313
* [PDO](https://www.php.net/manual/en/book.pdo.php)
1414
* [MySQL Improved](https://www.php.net/manual/en/book.mysqli.php)
1515
* [Memcached](https://www.php.net/manual/en/book.memcached.php)
1616
* [phpredis](https://github.com/phpredis/phpredis)
1717

18-
## Support PHP library
18+
## Supported PHP library
1919

2020
* [predis](https://github.com/predis/predis)

docs/menu.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,18 @@
1414
# limitations under the License.
1515

1616
catalog:
17-
- name: "PHP Agent Setup"
18-
path: "/en/setup/service-agent/php-agent/readme"
17+
- name: "Get Started"
18+
catalog:
19+
- name: "PHP Agent Setup"
20+
path: "/en/setup/service-agent/php-agent/readme"
1921
- name: "Plugins"
2022
catalog:
2123
- name: "Supported SAPI, extension and library"
2224
path: "/en/setup/service-agent/php-agent/Supported-list"
25+
- name: "Configuration"
26+
catalog:
27+
- name: "INI Settings"
28+
path: "/en/configuration/ini-settings"
2329
- name: "Contribution"
2430
catalog:
2531
- name: "Compiling Guidance"

0 commit comments

Comments
 (0)