Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dinky
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangpeng
dinky
Commits
670d0e8d
Unverified
Commit
670d0e8d
authored
Dec 03, 2022
by
ZackYoung
Committed by
GitHub
Dec 03, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Fix][k8s]k8s_fix (#1366)
* k8s_fix * k8s_fix
parent
3c0dae5e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
13 deletions
+14
-13
pom.xml
dlink-admin/pom.xml
+1
-0
ClusterConfigurationServiceImpl.java
...m/dlink/service/impl/ClusterConfigurationServiceImpl.java
+10
-11
DinkyFlinkDockerfile
dlink-admin/src/main/resources/DinkyFlinkDockerfile
+3
-2
No files found.
dlink-admin/pom.xml
View file @
670d0e8d
...
...
@@ -283,6 +283,7 @@
<!--注意这玩意默认从编译结果目录开始算目录结构-->
<exclude>
/application*.yml
</exclude>
<exclude>
/mybatis*.xml
</exclude>
<exclude>
/DinkyFlinkDockerfile
</exclude>
</excludes>
</configuration>
<executions>
...
...
dlink-admin/src/main/java/com/dlink/service/impl/ClusterConfigurationServiceImpl.java
View file @
670d0e8d
...
...
@@ -110,19 +110,18 @@ public class ClusterConfigurationServiceImpl extends SuperServiceImpl<ClusterCon
if
(
kubernetesConfig
.
containsKey
(
"kubernetes.container.image"
))
{
gatewayConfig
.
getFlinkConfig
().
getConfiguration
().
put
(
"kubernetes.container.image"
,
kubernetesConfig
.
get
(
"kubernetes.container.image"
).
toString
());
}
}
String
fileDir
=
FileUtil
.
isDirectory
(
PathConstant
.
WORK_DIR
+
"/dlink-doc"
)
?
PathConstant
.
WORK_DIR
+
"/dlink-doc"
:
PathConstant
.
WORK_DIR
;
File
dockerFile
=
null
;
try
{
dockerFile
=
FileUtil
.
writeUtf8String
(
FileUtil
.
readUtf8String
(
dockerfileResource
.
getFile
()),
fileDir
+
"/DinkyFlinkDockerfile"
);
Docker
docker
=
Docker
.
build
((
Map
)
getClusterConfigById
(
clusterConfiguration
.
getId
()).
getConfig
().
get
(
"dockerConfig"
));
if
(
docker
!=
null
&&
StringUtils
.
isNotBlank
(
docker
.
getInstance
()))
{
new
DockerClientUtils
(
docker
,
dockerFile
).
initImage
();
String
fileDir
=
FileUtil
.
isDirectory
(
PathConstant
.
WORK_DIR
+
"/dlink-doc"
)
?
PathConstant
.
WORK_DIR
+
"/dlink-doc"
:
PathConstant
.
WORK_DIR
;
File
dockerFile
=
null
;
try
{
dockerFile
=
FileUtil
.
writeUtf8String
(
FileUtil
.
readUtf8String
(
dockerfileResource
.
getFile
()),
fileDir
+
"/DinkyFlinkDockerfile"
);
Docker
docker
=
Docker
.
build
((
Map
)
getClusterConfigById
(
clusterConfiguration
.
getId
()).
getConfig
().
get
(
"dockerConfig"
));
if
(
docker
!=
null
&&
StringUtils
.
isNotBlank
(
docker
.
getInstance
()))
{
new
DockerClientUtils
(
docker
,
dockerFile
).
initImage
();
}
}
catch
(
Exception
e
)
{
throw
new
RuntimeException
(
e
);
}
}
catch
(
Exception
e
)
{
throw
new
RuntimeException
(
e
);
}
return
JobManager
.
testGateway
(
gatewayConfig
);
}
}
dlink-admin/src/main/resources/DinkyFlinkDockerfile
View file @
670d0e8d
# 用来构建dinky环境
FROM flink:1.14.5
ARG FLINK_VERSION=1.14.5
FROM flink:${FLINK_VERSION}
ENV PYTHON_HOME /opt/miniconda3
...
...
@@ -10,7 +11,7 @@ RUN ./miniconda.sh -b -p $PYTHON_HOME && chown -R flink $PYTHON_HOME && ls $PYTH
USER flink
ENV PATH $PYTHON_HOME/bin:$PATH
RUN pip install "apache-flink==
1.14.5
" -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
RUN pip install "apache-flink==
${FLINK_VERSION}
" -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
RUN cp /opt/flink/opt/flink-python_* /opt/flink/lib/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment