Skip to content

Deployment

klamir051 edited this page May 10, 2019 · 2 revisions

Preparation

The following software should be downloaded in advance

  • docker CE engine (offline)[https://docs.docker.com/install/linux/docker-ce/binaries/]
  • docker compose (install instructions)[https://docs.docker.com/compose/install/]

Extend disk space

By default the vm teplasweb1 has only 12 gb available space therefore you'll need to extend at least to 50 gb (expand disk space)[https://www.geoffstratton.com/expand-hard-disk-ubuntu-lvm]

Copy software from esx to ubuntu vm

In order to copy the files you'll need to plug in the usb stick and then copy the files to a local disk and then use pscp for copying the files to the targe machine. for example

pscp -r -i C:\Temp\ trpadmin@teplasweb1:/usr/trpadmin/

Deployment process

build the docker images locally

λ docker-compose build
dispolistdb uses an image, skipping
Building dispolist
Step 1/16 : FROM microsoft/dotnet:2.2-aspnetcore-runtime AS base
 ---> 41db56126a6d
Step 2/16 : WORKDIR /app
 ---> Using cache
 ...
 
Successfully built 54e43f8f2ceb
Successfully tagged ristlbat17/dispolist:2019-Woche1

export the image to usb stick

λ docker save -o dispolist ristlbat17/dispolist:2019-Woche1

then copy the images to ubuntu vm teplasweb1 as described above

loading the images from file

λ sudo docker load -i dispolist
Loaded image: ristlbat17/dispolist:2019-Woche1

run the new version

sudo docker-compose up -d

ristlbat17disposition_dispolistdb_1 is up-to-date
Recreating 7f4b5d7d0a44_ristlbat17disposition_dispolist_1 ... done