diff --git a/README.md b/README.md index ad528eb..324c6b1 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,14 @@ To bring up the mc-application-manager service along with its dependencies, run sudo apt update sudo apt install -y docker-compose +cd ./script +chmod +x setup-docker-no-sudo.sh +./setup-docker-no-sudo.sh + +cd .. +# The initial user information for the workflow engine is admin / 123456 +# The initial user information for the repository is admin / 123456 +# If you need to modify, modify docker-compose.yaml sudo docker-compose up -d ``` This command will pull the necessary Docker images, build the services, and start the containers in detached mode. @@ -76,6 +84,27 @@ Once the services are up, you can access the following endpoints: - Repository Management: `http://:18084/web/repository/list` - Yaml Generator: `http://:18084/web/generate/yaml` +### Step 4-1: Certainly! Here’s the translated list of settings: +1. Access the OSS List +2. Modify previously registered OSS +3. Update with Workflow Engine And Repository information +4. Check for duplicates and verify connections +5. Click the "Edit" button + +※ If no separate modifications were made, the Workflow Engine (Jenkins) information is as follows. +1. APE (Application Provisioning Engine) - Jenkins +> URL : http://:9800 +> +> OSS ID : admin +> +> OSS PW : 123456 + +2. Repository - Nexus +> URL : http://:8081 +> +> OSS ID : admin +> +> OSS PW : 123456 ### Step 5: Stop Services To stop the running services, use: @@ -144,65 +173,6 @@ If you prefer to build and run the project manually, follow these steps: . $PROJECT_ROOT/script/run-mc-application.sh ``` -### Refer to Set Application-Provisioning-Engine(Jenkins) -**1. Access the Jenkins container** -```bash -sudo docker exec -it ape-jenkins /bin/bash -``` - -**2. Inside the container, retrieve the initial admin password** -```bash -cat /var/jenkins_home/secrets/initialAdminPassword -``` - -**3. Copy the string that appears after running the cat command.** - -**4. Open Chrome browser and navigate to `http://:9800` Jenkins Unlock Page** -![img_4.png](document/img_4.png) -**5. Paste the copied string into the password field.** - -**6. Click `Install suggested plugins` Button** -![img_5.png](document/img_5.png) -![img_6.png](document/img_6.png) - -**7. Insert User Information** -![img_1.png](document/img_1.png) -![img_2.png](document/img_2.png) -![img_3.png](document/img_3.png) - -**This process will complete the initial setup of Jenkins** - -### Refer to Set Repository(Nexus) -**1. Access the Nexus container** -```bash -sudo docker exec -it nexus-repository /bin/bash -``` - -**2. Inside the container, retrieve the initial admin password** -```bash -cat /nexus-data/admin.password -``` -**3. Copy the string that appears after running the cat command.** - -**4. Open Chrome browser and navigate to `http://:8081` Nexus Unlock Page** -![img.png](document/nexusMain.png) -**5. Paste the copied string into the password field. (ID: admin)** - -**6. Click `Next` Button** -![img.png](document/setup1.png) - -**7. Insert New Password** -![img_1.png](document/setup2.png) - -**8. After selecting one, click the next button** -![img_2.png](document/setup3.png) - -**9. click the finish button** -![img_3.png](document/setup4.png) - -**This process will complete the initial setup of Nexus** ---- - ## Contributing We welcome contributions to the **mc-application-manager** project! To get involved, follow these steps: diff --git a/docker-compose.yaml b/docker-compose.yaml index 2eae5b8..2f97768 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -9,7 +9,8 @@ networks: services: # jenkins - for workflow manager jenkins: - image: jenkins/jenkins:jdk17 + image: bitnami/jenkins:2.462.3 + user: root container_name: ape-jenkins platform: linux/amd64 networks: @@ -24,9 +25,33 @@ services: - /var/run/docker.sock:/var/run/docker.sock - /usr/bin/docker:/usr/bin/docker # -v $(which docker):/usr/bin/docker environment: - - PROJECT=mcmp + JENKINS_USERNAME: admin + JENKINS_PASSWORD: 123456 # Please CHANGE ME + JENKINS_PLUGINS: >- + workflow-api, + swarm, + authorize-project, + antisamy-markup-formatter, + pipeline-github-lib, + pipeline-rest-api, + git, + github-branch-source, + gradle, + pipeline-model-definition, + pipeline-build-step, + workflow-aggregator, + matrix-project, + email-ext, + durable-task, + checks-api, + build-timeout, + timestamper, + ws-cleanup, + ssh-slaves, + ssh-agent, + publish-over-ssh healthcheck: # for application-manager - test: [ "CMD", "curl", "-f", "http://localhost:1024/catalog/software" ] + test: [ "CMD", "curl", "-f", "http://localhost:8080/login" ] interval: 1m timeout: 5s retries: 3 @@ -50,9 +75,10 @@ services: volumes: - ~/:/nexus-data/blobs/ environment: - - PROJECT=mcmp + NEXUS_SECURITY_RANDOMPASSWORD: 'false' + NEXUS_SECURITY_INITIAL_PASSWORD: 123456 # Please CHANGE ME healthcheck: # for application-manager - test: [ "CMD", "curl", "-f", "http://localhost:1024/catalog/software" ] + test: [ "CMD", "curl", "-f", "http://localhost:8081/login" ] interval: 1m timeout: 5s retries: 3 @@ -72,8 +98,8 @@ services: - ./db/application:/db/application environment: - DDL_AUTO=create-drop - - DB_USER=application - - DB_PASS=application!23 + - DB_USER=application # Please CHANGE ME + - DB_PASS=application!23 # Please CHANGE ME - SQL_DATA_INIT=always # or never healthcheck: # for cb-application-manager test: ["CMD", "nc", "-vz", "localhost", "1324"] diff --git a/document/img.png b/document/img.png deleted file mode 100644 index 48859ee..0000000 Binary files a/document/img.png and /dev/null differ diff --git a/document/img_1.png b/document/img_1.png deleted file mode 100644 index a5433f1..0000000 Binary files a/document/img_1.png and /dev/null differ diff --git a/document/img_2.png b/document/img_2.png deleted file mode 100644 index 3694f7c..0000000 Binary files a/document/img_2.png and /dev/null differ diff --git a/document/img_3.png b/document/img_3.png deleted file mode 100644 index 719ffef..0000000 Binary files a/document/img_3.png and /dev/null differ diff --git a/document/img_4.png b/document/img_4.png deleted file mode 100644 index 120de88..0000000 Binary files a/document/img_4.png and /dev/null differ diff --git a/document/img_5.png b/document/img_5.png deleted file mode 100644 index 0b4a0af..0000000 Binary files a/document/img_5.png and /dev/null differ diff --git a/document/img_6.png b/document/img_6.png deleted file mode 100644 index 466a39e..0000000 Binary files a/document/img_6.png and /dev/null differ diff --git a/document/nexusMain.png b/document/nexusMain.png deleted file mode 100644 index 152215e..0000000 Binary files a/document/nexusMain.png and /dev/null differ diff --git a/document/setup1.png b/document/setup1.png deleted file mode 100644 index 8b3603c..0000000 Binary files a/document/setup1.png and /dev/null differ diff --git a/document/setup2.png b/document/setup2.png deleted file mode 100644 index 1dfee84..0000000 Binary files a/document/setup2.png and /dev/null differ diff --git a/document/setup3.png b/document/setup3.png deleted file mode 100644 index 668cc57..0000000 Binary files a/document/setup3.png and /dev/null differ diff --git a/document/setup4.png b/document/setup4.png deleted file mode 100644 index e7e244b..0000000 Binary files a/document/setup4.png and /dev/null differ diff --git a/script/setup-docker-no-sudo.sh b/script/setup-docker-no-sudo.sh new file mode 100644 index 0000000..7732326 --- /dev/null +++ b/script/setup-docker-no-sudo.sh @@ -0,0 +1,30 @@ +#!/bin/bash + +# Docker 그룹 생성 (이미 존재하는 경우 무시) +sudo groupadd docker + +# 현재 사용자를 docker 그룹에 추가 +sudo usermod -aG docker $USER + +# Docker 데몬 재시작 +sudo systemctl restart docker + +# Docker 소켓 파일의 권한 변경 +sudo chmod 666 /var/run/docker.sock + +# 새 그룹 멤버십 적용 +newgrp docker << EOF + +# Docker 버전 확인 +docker -v + +# 실행 중인 컨테이너 확인 +docker ps + +echo "Docker 설정이 완료되었습니다. 이제 sudo 없이 Docker를 사용할 수 있습니다." +echo "주의: Docker 소켓 파일의 권한을 666으로 변경했습니다. 이는 보안상 권장되지 않을 수 있습니다." +echo "시스템 전체에 영구적으로 적용하려면 로그아웃 후 다시 로그인하는 것이 좋습니다." + +# 사용자가 현재 셸을 계속 사용할 수 있도록 함 +$SHELL +EOF \ No newline at end of file