Updated README.md and Jenkinsfile.

This commit is contained in:
2023-01-12 14:42:12 +01:00
parent 0d4974b0ea
commit 13995a0269
3 changed files with 2 additions and 48 deletions

2
Jenkinsfile vendored
View File

@@ -1,6 +1,6 @@
node('master'){
stage('git') {
git branch: 'developer', credentialsId: '4b557b80-6257-46a3-9072-bb07ba228cff', url: 'ssh://_git@phabricator.release11.com/source/mockedservices.git'
git branch: 'developer', credentialsId: '4b557b80-6257-46a3-9072-bb07ba228cff', url: '_gitea@gitea.release11.com:R11/mockedservices.git'
}
stage('deploy'){
sh 'docker-compose --context gordon down'

View File

@@ -1,8 +1,6 @@
# R11-MockedServices
Mockup service for middleware testing.
[comment]: <> ([![Build Status]&#40;https://travis-ci.com/Szakalakamaka/Klaus.svg?token=Tt3QbF7q4wiFNnCGkuew&branch=master&#41;]&#40;https://travis-ci.com/Szakalakamaka/Klaus&#41;)
Available scripts:
### Running the application on a local machine
@@ -47,47 +45,4 @@ Display elements from the list.
Display list length.
###### SMEMBERS key
Display elements from hashSet.
Logs can be found in lists with names logstash_yyyy-mm-dd.
### Deployment and building with docker and jenkins
For creating docker context (feature available from docker version 19.03) run the command
#### docker context create
as shown by examples below.
```
docker context create DEV \
--description "context for DEV environment" \
--docker "host=ssh://jenkins@s5000xvn:22"
```
```
docker context create PROD \
--description "connection to PROD environment" \
--docker "host=ssh://jenkins@server361209.nazwa.pl:22"
```
```
docker context create PROD \
--description "context for PROD environment" \
--docker "host=ssh://jenkins@server361209:22"
```
However it is highly adviseable to deploy service via Jenkins tool at jenkins.zipper.release11.com, where contexts have been already configured.
#### docker-compose up -d --build
Builds and launches Redis service and the application. Performs unit testing on the code and run the applicationon on localhost.
#### docker-compose --context DEV up --build -d
The same as above, but the application will be deployed on the server defined via docker context as DEV.
#### docker-compose --context PROD up --build -d
The same as above, but the application will be deployed on the server defined via docker context as PROD.
The application can be started on a local machine without environment support.
Once a docker image repository will be availabe, the proper deployment order should be under control by docker-compose script
which should check if the applications are present and if not deploy stable images of Spring Cloud applications from
docker image repo.
Logs can be found in lists with names logstash_yyyy-mm-dd.

View File

@@ -3,7 +3,6 @@ package com.release11.klaus;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
/**
* It's generic Spring context starter. Move along...
*