WebSphere 워크로드의 마이그레이션 계획 맞춤설정

시작하기 전에

이 문서에서는 개발자가 이미 마이그레이션을 만들었고 마이그레이션 계획 파일이 있다고 가정합니다.

마이그레이션 계획 수정

파일 시스템을 복사하고 분석한 후 지정된 출력 경로 ANALYSIS_OUTPUT_PATH/config.yaml에 생성된 새 디렉터리에서 마이그레이션 계획을 찾을 수 있습니다.

필요에 따라 마이그레이션 계획을 수정하고 변경사항을 저장합니다.

마이그레이션 계획 세부정보와 안내를 검토하여 필요에 따라 정보를 추가합니다.

특히 다음 섹션을 수정하는 것이 좋습니다.

마이그레이션 계획 구조

WebSphere 워크로드의 마이그레이션 계획 구조는 다음 섹션에 설명된 대로 맞춤설정할 수 있습니다.

# List of discovered WebSphere application servers and how to migrate their
# hosted applications to containers.
webSphereApplicationServers:
# The application server installation path.
- home: /opt/ibm/wlp
  applicationServerInfo:
    name: WebSphere Application Server
    profile: Liberty
    version: 23.0.0.4
    edition: Base
    # List of Java installations available to the application server.
    javaDevelopmentKits:
    - home: /opt/ibm/java
      vendor: IBM Corporation
      version:
        jdk: java version 1.8.0_361
        jre: Java(TM) SE Runtime Environment
        jvm: IBM J9 VM
  # List of hosted applications and how to migrate them to containers.
  applications:
  - path: /opt/ibm/wlp/usr/servers/defaultServer/apps/app.war
    # Application archives to be migrated into the target container.
    archives:
    - /opt/ibm/wlp/usr/servers/defaultServer/apps/app.war
    # Application configuration files to be migrated into the target container.
    configurations:
      serverXML: /opt/ibm/wlp/usr/servers/defaultServer/server.xml
      serverEnv:
      - /opt/ibm/wlp/usr/servers/defaultServer/server.env
      bootstrapProperties:
      - /opt/ibm/wlp/usr/servers/defaultServer/bootstrap.properties
      variableProperties:
      - /opt/ibm/wlp/usr/servers/defaultServer/variables/variable.properties
      jvmOptions:
      - /opt/ibm/wlp/usr/servers/defaultServer/jvm.options
    # Application resource files to be migrated into the target container.
    resources:
      locations:
      - /opt/ibm/wlp/usr/servers/defaultServer/resources/ports.xml
      libraries:
      - /opt/ibm/wlp/usr/servers/defaultServer/resources/postgresql.jar
      keystores:
      - /opt/ibm/wlp/output/defaultServer/resources/security/key.p12
      sharedResources:
        - /opt/ibm/wlp/usr/shared/resources/jdbc.jar
      additionalResources:
      - /opt/ibm/wlp/output/defaultServer/resources/mongodb.jar
    javaRuntime:
      se: SE8
      ee: EE7
      vendor: IBM Corporation
    targetJavaRuntime:
      se: SE8
      ee: EE7
      vendor: IBM Corporation
    targetApplicationServer:
      profile: Liberty
      version: 23.0.0.4
      edition: Base
    targetContainer:
      # The target container base image name.
      baseImage: ibmcom/websphere-liberty:full-java8-ibmjava-ubi
      # The application server installation path within the target container
      # base image.
      home: /opt/ibm/wlp
      # The application server default server name.
      server: defaultServer
      # The UID or name of the user configured within the target container
      # base image. Defaults to 1001 for Liberty profile.
      user: "1001"
      # The GID or name of the group configured within the target container
      # base image. Defaults to 0 for Liberty profile.
      group: "0"
      # Application ports to be exposed in Kubernetes artifacts.
      ports:
      - name: http-tcp-9080
        port: 9080
        protocol: TCP
      - name: https-tcp-9443
        port: 9443
        protocol: TCP
      # Specify whether discovered keystores are automatically converted to
      # Kubernetes secrets. Defaults to true.
      enableSecrets: true

애플리케이션 제외

마이그레이션에서 애플리케이션을 제외하려면 applications 목록에서 애플리케이션을 삭제합니다.

  applications:
  # Exclude app1.war:
  # - path: app1.war
  #  ...
  - path: app2.war

애플리케이션 파일 제어

마이그레이션에 포함하거나 제외할 애플리케이션 파일을 제어하려면 configurationsresources 필드를 업데이트합니다.

  applications:
  - path: app.war
    resources:
      keystores:
      # Exclude key1.p12:
      # - key1.p12
      # Include key2.p12:
      - key2.p12
      additionalResources:
      # Exclude resource1.xml:
      # - resource1.xml
      # Include resource2.xml:
      - resource2.xml

대상 Java 런타임 맞춤설정

애플리케이션의 대상 Java 런타임을 맞춤설정하려면 targetJavaRuntime 필드를 업데이트합니다.

  applications:
  - path: app.war
    targetJavaRuntime:
      se: SE
      ee: EE
      vendor: VENDOR

다음을 바꿉니다.

  • SE: Java SE 버전. 형식은 [SE8|SE11|SE17]입니다.
  • EE: Java EE 또는 자카르타 EE 버전. 형식은 [EE7|EE8|EE9|EE10]입니다.
  • VENDOR: Java 공급업체. 형식은 [IBM Corporation|Oracle Corporation]입니다.

대상 애플리케이션 서버 맞춤설정

애플리케이션의 대상 애플리케이션 서버를 맞춤설정하려면 targetApplicationServer 필드를 업데이트합니다.

  applications:
  - path: app.war
    targetApplicationServer:
      profile: PROFILE
      version: VERSION
      edition: EDITION

다음을 바꿉니다.

  • PROFILE: WebSphere 프로필. 형식은 [Liberty|traditional]입니다.
  • TARGET_VERSION: WebSphere 버전
  • TARGET_EDITION: WebSphere 버전. 형식은 [Base|Core|Open|ND]입니다.

대상 컨테이너 맞춤설정

애플리케이션에 사용할 대상 컨테이너를 맞춤설정하려면 targetContainer 필드를 업데이트합니다.

  applications:
  - path: app.war
    targetContainer:
      baseImage: BASE_IMAGE
      home: HOME
      server: SERVER
      user: USER
      group: GROUP

Kubernetes 보안 비밀 맞춤설정

기본적으로 keystores 필드에 나열된 파일은 Kubernetes 보안 비밀로 마이그레이션됩니다. 이 파일을 있는 그대로 마이그레이션하려면 이 기능을 사용 중지하면 됩니다.

  applications:
  - path: app.war
    resources:
      keystores:
      - key.p12
    targetContainer:
      # Do not migrate keystores to Kubernetes secrets:
      enableSecrets: false

Kubernetes 포트 맞춤설정

Kubernetes 포드 및 서비스에서 노출되는 포트를 제어하려면 ports 필드를 업데이트합니다.

  applications:
  - path: app.war
    targetContainer:
      ports:
      # Exclude http-tcp-9080:
      # - name: http-tcp-9080
      #   port: 9080
      #   protocol: TCP
      # Include https-tcp-9443:
      - name: https-tcp-9443
        port: 9443
        protocol: TCP

다음 단계