ww664853070 1 year ago
parent
commit
be45c8cbb4
  1. 2
      doc/scripts/tools/v3.22.1_init_HRM_resource/Dockerfile
  2. 4
      doc/scripts/tools/v3.22.1_init_HRM_resource/config.js
  3. 21
      doc/scripts/tools/v3.22.1_init_HRM_resource/jenkinsfilenew
  4. 21
      jenkinsfilenew

2
doc/scripts/tools/v3.22.1_init_HRM_resource/Dockerfile

@ -6,7 +6,7 @@ COPY . /app
WORKDIR /app
RUN npm cache clean -f && npm install --production --force --registry http://10.8.30.22:7000
RUN npm cache clean -f && npm install --production --force --registry https://nexus.ngaiot.com/repository/fs-npm/
CMD [ "node", "index.js" ]

4
doc/scripts/tools/v3.22.1_init_HRM_resource/config.js

@ -6,10 +6,10 @@ const ENV_SY_POOL = { //商用数据库配置
port: 5432
}
const ENV_CS_POOL = { //生产环境数据库配置
user: 'postgres',
user: 'FashionAdmin',
host: '10.8.30.166',
database: 'HRM',
password: '123',
password: '123456',
port: 5432
}
const PRO_POOL = { //研发自测用

21
doc/scripts/tools/v3.22.1_init_HRM_resource/jenkinsfilenew

@ -0,0 +1,21 @@
podTemplate {
node('pod-templ-jenkins-slave-common') {
env.IMAGE_NAME = "${IOT_IMAGES_REGISTRY}/${pep}/${JOB_NAME}"
env.IMAGE_NAME_SHORT = "${pep}/${JOB_NAME}"
env.CODE_ADDR = "${GIT_ADDRESS}/free-sun/HumanResource.git"
stage('Run shell') {
git branch: 'master', credentialsId: 'gitea-builder', url: "${CODE_ADDR}"
container('image-builder') {
sh'''
/kaniko/executor --context=${BUILD_WORKSPACE} --dockerfile=./doc/scripts/tools/v3.22.1_init_HRM_resource/Dockerfile --destination=${IMAGE_NAME}:${IMAGE_VERSION} --cache=false --cleanup
'''
}
buildName "${IMAGE_NAME_SHORT}:${IMAGE_VERSION}"
buildDescription "${IMAGE_NAME}:${IMAGE_VERSION}"
}
}
}

21
jenkinsfilenew

@ -0,0 +1,21 @@
podTemplate {
node('pod-templ-jenkins-slave-common') {
env.IMAGE_NAME = "${IOT_IMAGES_REGISTRY}/${pep}/${JOB_NAME}"
env.IMAGE_NAME_SHORT = "${pep}/${JOB_NAME}"
env.CODE_ADDR = "${GIT_ADDRESS}/free-sun/HumanResource.git"
stage('Run shell') {
git branch: 'master', credentialsId: 'gitea-builder', url: "${CODE_ADDR}"
container('image-builder') {
sh'''
/kaniko/executor --context=${BUILD_WORKSPACE} --dockerfile=./doc/scripts/tools/v3.22.1_init_HRM_resource/Dockerfile --destination=${IMAGE_NAME}:${IMAGE_VERSION} --cache=false --cleanup
'''
}
buildName "${IMAGE_NAME_SHORT}:${IMAGE_VERSION}"
buildDescription "${IMAGE_NAME}:${IMAGE_VERSION}"
}
}
}
Loading…
Cancel
Save