Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
geoserver
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
backend
geoserver
Commits
37686804
Commit
37686804
authored
Sep 19, 2019
by
胡凯旋
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add dockerfile/jenkinsfile
parent
dbfb565b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
96 additions
and
0 deletions
+96
-0
Dockerfile
Dockerfile
+51
-0
Jenkinsfile
Jenkinsfile
+45
-0
No files found.
Dockerfile
0 → 100644
View file @
37686804
FROM
ccr.ccs.tencentyun.com/gm-base/gm-alpine:v1.3
COPY
./requirements.txt /tmp
RUN
apk add
--no-cache
--virtual
.build-deps
\
bzip2-dev
\
coreutils
\
dpkg-dev dpkg
\
expat-dev
\
findutils
\
gcc
\
gdbm-dev
\
libc-dev
\
libffi-dev
\
libnsl-dev
\
libressl-dev
\
libtirpc-dev
\
linux-headers
\
make
\
ncurses-dev
\
pax-utils
\
readline-dev
\
sqlite-dev
\
tcl-dev
\
tk
\
tk-dev
\
xz-dev
\
zlib-dev
\
# 业务相关依赖和安装工具
linux-headers \
python3-dev \
librdkafka-dev \
mariadb-client \
mariadb-dev \
git \
openssh \
\
# 取消ssh第一次链接的确认
&& echo "StrictHostKeyChecking no" >> /etc/ssh/ssh_config \
&& apk add --no-cache mariadb-connector-c-dev libxml2-dev libxslt-dev librdkafka-dev \
&& pip install --no-cache-dir -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com -r /tmp/requirements.txt \
&& mkdir -p /data/log/geoserver/app
COPY
. /srv/apps/geoserver/
RUN
pip
install
git+ssh://git@git.wanmeizhensuo.com/backend/gm-types.git@master
\
&&
apk del .build-deps
WORKDIR
/srv/apps/geoserver/
CMD
gunicorn gm_rpcd.wsgi:application -w 5 -k gevent -b 0.0.0.0:8000 --access-logfile /data/log/geoserver/app/gunicorn_access.log --error-logfile /data/log/geoserver/app/gunicorn_error.log
Jenkinsfile
0 → 100644
View file @
37686804
@Library
(
'gm-pipeline-library'
)
_
pipeline
{
agent
any
options
{
// Console output add timestamps
timestamps
()
// Disallow concurrent executions of the Pipeline
disableConcurrentBuilds
()
// On failure, retry the entire Pipeline the specified number of times.
retry
(
1
)
}
parameters
{
choice
(
name:
'CACHE'
,
choices:
[
''
,
'--no-cache'
],
description:
'docker build 是否使用cache,默认使用,不使用为--no-cache'
)
}
environment
{
// Image Tag branch.time.hash
TAG
=
dockerTag
()
// Image Full Tag
IMAGE
=
"${DOCKER_REGISTRY}/gm-backend/geoserver:$TAG"
}
stages
{
stage
(
"Begin"
)
{
steps
{
dingNotify
"before"
}
}
stage
(
'Build Image'
)
{
steps
{
sh
"docker build . ${params.CACHE} -t $IMAGE -f ./Dockerfile"
sh
"docker push $IMAGE"
}
}
}
post
{
always
{
dingNotify
"after"
,
"${currentBuild.currentResult}"
}
}
}
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