Skip to content

Commit 1a4669d

Browse files
committed
nit
1 parent 64971b1 commit 1a4669d

File tree

1 file changed

+82
-1
lines changed

1 file changed

+82
-1
lines changed

website/docs/quickstart/flink.md

Lines changed: 82 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,12 +116,93 @@ You can also visit http://localhost:8083/ to see if Flink is running normally.
116116

117117
:::note
118118
- If you want to additionally use an observability stack, follow one of the provided quickstart guides [here](maintenance/observability/quickstart.md) and then continue with this guide.
119-
- If you want to run with your own Flink environment, remember to download the [fluss-flink connector jar](/downloads), [flink-connector-faker](https://github.com/knaufk/flink-faker/releases) and then put them to `FLINK_HOME/lib/`.
120119
- All the following commands involving `docker compose` should be executed in the created working directory that contains the `docker-compose.yml` file.
121120
:::
122121

123122
Congratulations, you are all set!
124123

124+
If you want to run with your own Flink environment, you can follow the following instructions.
125+
126+
1. Download the desired Flink version (The following example takes Apache Flink 1.20 as an example.)
127+
128+
```shell
129+
wget https://dlcdn.apache.org/flink/flink-1.20.3/flink-1.20.3-bin-scala_2.12.tgz; tar -zxvf flink-1.20.3-bin-scala_2.12.tgz
130+
```
131+
132+
2. Download [fluss-flink connector jar](/downloads), [flink-connector-faker](https://github.com/knaufk/flink-faker/releases) and then put them to `FLINK_HOME/lib/`.
133+
134+
3. Create a `docker-compose.yml` file with the following content:
135+
136+
```yaml
137+
services:
138+
#begin Fluss cluster
139+
coordinator-server:
140+
image: apache/fluss:$FLUSS_DOCKER_VERSION$
141+
command: coordinatorServer
142+
depends_on:
143+
- zookeeper
144+
environment:
145+
- |
146+
FLUSS_PROPERTIES=
147+
zookeeper.address: zookeeper:2181
148+
bind.listeners: FLUSS://coordinator-server:9123
149+
remote.data.dir: /tmp/fluss/remote-data
150+
tablet-server:
151+
image: apache/fluss:$FLUSS_DOCKER_VERSION$
152+
command: tabletServer
153+
depends_on:
154+
- coordinator-server
155+
environment:
156+
- |
157+
FLUSS_PROPERTIES=
158+
zookeeper.address: zookeeper:2181
159+
bind.listeners: FLUSS://tablet-server:9123
160+
data.dir: /tmp/fluss/data
161+
remote.data.dir: /tmp/fluss/remote-data
162+
kv.snapshot.interval: 0s
163+
zookeeper:
164+
restart: always
165+
image: zookeeper:3.9.2
166+
#end
167+
#begin Flink cluster
168+
flink-standalone:
169+
image: apache/fluss-quickstart-flink:1.20-$FLUSS_DOCKER_VERSION$
170+
ports:
171+
- "8083:8081"
172+
command: jobmanager
173+
environment:
174+
- |
175+
FLINK_PROPERTIES=
176+
jobmanager.rpc.address: jobmanager
177+
taskmanager:
178+
image: apache/fluss-quickstart-flink:1.20-$FLUSS_DOCKER_VERSION$
179+
depends_on:
180+
- jobmanager
181+
command: taskmanager
182+
environment:
183+
- |
184+
FLINK_PROPERTIES=
185+
jobmanager.rpc.address: flink-standalone
186+
taskmanager.numberOfTaskSlots: 10
187+
taskmanager.memory.process.size: 2048m
188+
taskmanager.memory.framework.off-heap.size: 256m
189+
#end
190+
```
191+
192+
4. To start all containers, run:
193+
```shell
194+
docker compose up -d
195+
```
196+
This command automatically starts all the containers defined in the Docker Compose configuration in detached mode.
197+
198+
Run
199+
```shell
200+
docker container ls -a
201+
```
202+
to check whether all containers are running properly.
203+
204+
You can also visit http://localhost:8083/ to see if Flink is running normally.
205+
125206
## Enter into SQL-Client
126207
First, use the following command to enter the Flink SQL CLI Container:
127208
```shell

0 commit comments

Comments
 (0)