본문 바로가기
반응형

[AWS]354

52. 빌드 단계: Gitlab CI로 Java 애플리케이션 빌드 ## IntelliJ 에서 .gitlab-ci.yml 생성 후, 빌드 -> Jar 파일 생성 ## .gitlab-ci.yml stages: - build build: stage: build image: openjdk:12-alpine script: - ./gradlew build artifacts: paths: - ./build/libs/ ===================================================== Now that we know which command is responsible for building this type of project, it's not time to start building the catalepsy pipeline. So what I'm goin.. 2022. 2. 22.
51장. 빌드 단계: 로컬에서 Java 애플리케이션 빌드 ## CMD 빌드 방법 ## GUI 빌드 방법 (build - libs - cars-api.jar 파일 생성) ## GUI Clean 방법 (cars-api.jar 파일 삭제) ## 하기 내용시 재부팅 할것!! ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. Please set the JAVA_HOME variable in your environment to match the location of your Java installation. ## Gradle이란 무엇입니까? 개요 Gradle은 거의 모든 유형의 소프트웨어를 빌드할 수 있을 만큼 충분히 유연하도록 설계된 오픈 소스 빌드 자동화 도구입니다. 다음은 가.. 2022. 2. 21.
50장. 지속적 통합(CI) 파이프라인 개요 ====================================== We are ready to start building a pipeline for this project, and the first step is to start with the pipeline, obviously, because we first are trying to build something and after that we are trying to deploy it. If you remember, the pipeline typically has a few stages like build code, quality test and packaging the application for later use, especially for d.. 2022. 2. 21.
49장. Postman으로 API 호출하기 ## Import 로 Json 오픈, Localhost 로 설정 - CRUD 테스트 - 브라우저 조회가능 http://localhost:5000/cars https://www.youtube.com/watch?v=JzpFsrZnNDo http://pizzeria-valentino.herokuapp.com/api/orders http://pizzeria-valentino.herokuapp.com/api/auth =============================================== So after opening Posman, I will go to import. And are two files that need importing, the first one is the collection, th.. 2022. 2. 21.
48장. 자바 애플리케이션 소개 ## Gitlab 프로젝트 생성 https://gitlab.com/gitlab-course-public/cars-api gitlab-course-public / cars-api GitLab.com gitlab.com ## API란? API는 웹사이트와 같은 그래픽 인터페이스가 없는 프로그램입니다. 예를 들어 API는 프론트 엔드 애플리케이션 또는 모바일 애플리케이션에서 프로세스 또는 프로세스에서 데이터를 표시하는 데 사용됩니다. https://www.youtube.com/watch?v=iFMLyMgCUTs ## 사전 설치 개발 툴 https://www.jetbrains.com/idea/download/download-thanks.html?platform=windows&code=IIC Thank you f.. 2022. 2. 21.
47. Overview (Deploy JAVA To AWS Elastic Beanstalk) In this section, we increase the complexity of the application we are building and deploying, we'll be building and testing a job application and will deploy to Amazon Web Services, also known as a W.S. Anderson. If you're not a Java developer or you are not interested in using Java or A.W. with your projects, this section tries to provide you with a realistic example. I can assure you it is tot.. 2022. 2. 21.
46장. ​​작업 템플릿 만들기 ## .deploy_template 생성 후, - deploy staging, deploy production 상속 ## .gitlab-ci.yml image: node stages: - build - test - deploy review - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build only: - master - merge_requests script: -.. 2022. 2. 21.
45장. Anchors ## Anchors 활용 - 중복 콘텐츠 방지 - 다른 개체의 속성을 상속 https://codebeautify.org/yaml-to-json-xml-csv Best Online YAML Converter - Convert YAML Strings into JSON, XML, CSV codebeautify.org ====================================================== Yambo has a very nice feature called Anker's in the beginning, it does seem a bit weird to use it, but in this lecture I would try to explain you what anchors are, how .. 2022. 2. 21.
44. 작업 비활성화 ## 작업 비활성화시, 앞에 콤마(.) 생성 - 이전 단계의 종속성에 의존하지 않는다면 단순히 작업을 비활성화할 수 있습니다. .build website: .test artifact: ================================================= Sometimes you only may want to work on some specific jobs or in some specific stages, and when you're working on a specific stage, especially if it's towards the end, you don't really want for the entire thing to build and take so much time. So .. 2022. 2. 21.
43장. YAML 이해하기 ## YAML 이해하기 - 키와 값의 쌍 - 문자, 숫자 설정 가능 - True, False 설정 가능 - 목록 (List), 배열 (Array) 설정 가능 - 주석 (#) 허용 - JSON 은 주석 불가 - JSON 변환시 -----> List 도 Array 로 변경됨 person: name: John age: 29 isMale: true stuff: - laptop - car - bike food: [pizza, donuts, coke] friends: - name: Jane age: 19 - name: mike age: 22 { "person": { "name": "John", "age": 29, "isMale": true, "stuff": [ "laptop", "car", "bike" ], "fo.. 2022. 2. 21.
42장. YAML Overview Welcome to this new section where we will discuss Yamal Basics now the entire section is designed to give you an introduction to Yamal because so far we have used Yamal, but only just to help us to write the configuration that we needed. And we haven't really looked at what the angle is and how everything works together and why we have to write some things the way we have written them. So the id.. 2022. 2. 21.
41장. 요약 및 결론 Congratulation, this is the last lecture in dissection and yeah, I think we have done a good job because now we have gone over the most important features that get lab and get Lipsey offer us. I think one of the key takeaways in this one is especially related to environments and how we have to use them and that we have now the possibility of doing my request, deploying to dynamic environments, d.. 2022. 2. 21.
40장. before_script 및 after_script 구성 ## before_script 선택적 옵션 ## .gitlab-ci.yml image: node stages: - build - test - deploy review - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build only: - master - merge_requests script: - echo $CI_COMMIT_SHORT_SHA - npm install .. 2022. 2. 21.
39장. Destroying environments (Clean-up after the Merge Request) ## Master 로 Merge 진행시, 기존 Branch의 테스트 주소 삭제 작업 진행 ## .gitlab-ci.yml image: node stages: - build - test - deploy review - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build only: - master - merge_requests script: - echo $CI_COMMI.. 2022. 2. 21.
38장. 사용할 수 없는 환경 변수 문제 해결 Troubleshooting environment variables not being available Problem: Surge is not deploying. This solution is relevant if you are getting this message on the console output. The most likely cause for this is the environment variables not being available inside this branch. You can make sure this is the cause by using the echo command in your script. test job: script: - echo $SURGE_LOGIN Possible s.. 2022. 2. 20.
37장. Dynamic environments ## Deploy Review Job 추가 생성 - Branch 에서 소스변경 (feature/oky) - Master 로 Merge Requests 클릭 ## .gitlab-ci.yml image: node stages: - build - test - deploy review - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build only: - master - me.. 2022. 2. 20.
36장. 병합 요청 - 첫 번째 병합 요청 ## Feature/new title 브랜치에서 소스코드 수정 후, maser로 merge 수행 -> 빌드후, 웹배포 성공 - 배포 성공 후, Feature/new title 브랜치는 자동 삭제 ## .gitlab-ci.yml image: node stages: - build - test - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build only: - maste.. 2022. 2. 18.
35장. Merge requests - Configuring Gitlab ## Default Branch 설정 (main -> master) ## Protected branches - 아무도 변경사항을 master 로 푸시할 수 없음 ## Settings -> General -> Merge requests - Fast-forward merge 선택 - Merge checks -> Pipelines must succeed 선택 ================================== Meanwhile, we can do a few settings regarding marriage requests. So if we go to Settings Repository. There are a few things that we can configure to, for example, i.. 2022. 2. 18.
33장. Merge requests - Using branches ## 목적 : 배포는 master 브랜치만 설정 image: node stages: - build - test - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build script: - echo $CI_COMMIT_SHORT_SHA - npm install - npm install -g gatsby-cli - gatsby build - sed -i "s/%%VERSIO.. 2022. 2. 18.
34장. Merge requests - What is a Merge Request? Merge requests - What is a Merge Request? Merge Requests are a good way to visualize new changes that are about to be made in the master branch. Instead of making changes directly into master, the Merge Request workflow allows you to: allow others to review the changes allows the pipeline to run once without affecting others or the master branch allows for additional changes to be made and see t.. 2022. 2. 18.
32. 수동 배포 / 수동으로 작업 트리거 https://docs.gitlab.com/ee/ci/yaml/#whenmanual Keyword reference for the `.gitlab-ci.yml` file | GitLab Documentation for GitLab Community Edition, GitLab Enterprise Edition, Omnibus GitLab, and GitLab Runner. docs.gitlab.com https://docs.gitlab.com/ee/ci/yaml/#allow_failure Keyword reference for the `.gitlab-ci.yml` file | GitLab Documentation for GitLab Community Edition, GitLab Enterprise Edi.. 2022. 2. 18.
31. 변수 정의 ## .gitlab-ci.yml image: node stages: - build - test - deploy staging - deploy production - production tests cache: key: ${CI_COMMIT_REF_SLUG} paths: - node_modules/ variables: STAGING_DOMAIN: aido-stg.surge.sh PRODUCTION_DOMAIN: aido-pro.surge.sh build website: stage: build script: - echo $CI_COMMIT_SHORT_SHA - npm install - npm install -g gatsby-cli - gatsby build - sed -i "s/%%VERSION%%/$CI_C.. 2022. 2. 18.
[AWS] RDS 생성중 VPC 관련 에러가 발생하는 경우 RDS 생성중 아래와 같은 에러가 발생했다. Cannot create a publicly accessible DBInstance. The specified VPC does not support DNS resolution, DNS hostnames, or both. Update the VPC and then try again (Service: AmazonRDS; Status Code: 400; Error Code: InvalidVPCNetworkStateFault RDS를 public access 가능하게 하면 엔드포인트가 생성되는데, 접속을 시도해 보면 내부ip로 시도하게 된다. 구글링을 통해 찾은 해결방법 입니다. VPC의 "DNS 확인 편집"을 yes로 설정 VPC의 "DNS 호스트 이름 편집"을 y.. 2022. 2. 18.
[AWS] [활용] My Amazon EC2 Windows instance is unable to retrieve instance metadata. How can I fix this? ## Cloudwatch 설치시 에러 해결 https://www.youtube.com/watch?v=DEkrcNkF-4Q PS C:\Users\Administrator> & $Env:ProgramFiles\Amazon\AmazonCloudWatchAgent\amazon-cloudwatch-agent-ctl.ps1 -a fetch-config -m ec2 -c file:C:\Users\Administrator\Desktop\CWAgent\config.json -s ****** processing amazon-cloudwatch-agent ****** 2022/02/17 14:11:12 E! ec2metadata is not available I! detect region from ecs Unable to .. 2022. 2. 17.
[AWS] Monitoring - 3. CloudWatch Agent 설치[Memory/Disk 수집][Windows] 이번글에서는 Windows 에서 Memory/Disk를 수집하기 위해서 CloudWatch Agent 설치 방법에 대해서 글을 작성하도록 하겠습니다. 1. IAM 역할 부여 이전에 CloudWatch Agent 설치를 위해서 이전에 만들어둔 IAM 역할을 해당 Windows EC2 인스턴스에도 설정을 하도록 하겠습니다. 2. Windows 용 CloudWatch Agent 설치 Windows Server에 접속하도록 하겠습니다. Windows EC2 Server에 접속해서 폴더(CWAgent)를 생성해 줍니다. 이 생성된 폴더에 CWAgent를 설치할 예정입니다. 폴더 경로가 나와있는 곳에 위와 같이 cmd 라고 입력 합니다. 그러면 위와 같이 명령어를 입력할 수 있는 명령어 창이 나타납니다. curl .. 2022. 2. 17.
[AWS] 윈도우10 원하는 용량의 더미(Dummy)파일 생성하는 방법 PS D:\> fsutil file createnew filename 10737418240 fsutil file createnew (파일이름) (파일용량-단위Byte) 1MB = 1048576Byte 1GB = 1073741824Byte 1TB = 1099511627776Byte 1PB = 1125899906842624Byte https://blog.iroot.kr/237 2022. 2. 16.
[AWS] Monitoring - 2. CloudWatch Agent 설치 [Memory/Disk 수집][Linux OS] AWS Monitoring - 1. CloudWatch 대시보드 구성 Amazon CloudWatch는 애플리케이션을 모니터링하고, 시스템 전반의 성능 변경 사항에 대응하며, 리소스 사용률을 최적화하고, 운영 상태에 대한 통합된 보기를 확보하는 데 필요한 데이터와 실행 가� longtermsad.tistory.com 이번 글에서는 이전글에서 이야기 했듯이 CloudWatch는 기본적으로 Memory와 Disk에 대해서는 수집을 하지 못하기 때문에 수집을 하기 위해서는 CloudWatch Agent를 설치하고 설정해줘서 수집 및 대시보드로 구성해야 합니다. 이번 글에서는 CloudWatch Agent 설치[Linux OS]와 Dashboard 구성을 해보도록 하겠습니다. 1. IAM 역할 만들기 수집할 E.. 2022. 2. 16.
[AWS] Monitoring - 1. CloudWatch 대시보드 구성 Amazon CloudWatch는 애플리케이션을 모니터링하고, 시스템 전반의 성능 변경 사항에 대응하며, 리소스 사용률을 최적화하고, 운영 상태에 대한 통합된 보기를 확보하는 데 필요한 데이터와 실행 가능한 통찰력을 제공합니다. 요구 사항 : AWS Service 중 EC2 Instance, ELB(CLB, ALB, NLB), VPC에 해당하는 서비스들에 대한 Monitoring CloudWatch 대시보드 구성(EC2) AWS Console에 접속하여 필요로 하는 지표를 모아 대시보드를 생성 할 수 있습니다. 대시보드 생성을 클릭하면 아래와 같이 대시보드 이름을 입력하면 대시보드를 생성 할 수 있습니다. 대시보드를 생성하게 되면 아래와 같이 대시보드에 구성하게 될 위젯 타입을 선택하라는 화면이 나타납니.. 2022. 2. 16.
[AWS] 윈도우에서 AWS CLI 설치하기 AWS CLI(Command Line Interface)는 AWS사용을 간편하게 해주는 도구입니다. AWS EC2에서 아마존리눅스는 설치되어 있습니다. 1. 윈도우에 AWS 명령줄 인터페이스 설치하기 (CLI 버전1) AWS 명령줄 인터페이스 aws-shell은 명령줄 셸 프로그램으로서, AWS 명령줄 인터페이스를 사용하는 새로운 사용자와 고급 사용자 모두에게 도움이 되는 편의 기능 및 생산성 기능을 제공합니다. 주요 기능은 다음과 같습니다. 다음 항목에 대한 퍼지 자동 완료 명령(예: ec2, describe-instances, sqs, create-queue) 옵션(예: --instance-ids, --queue-url) 리소스 식별자(예: Amazon EC2 인스턴스 ID, Amazon aws.am.. 2022. 2. 16.
[AWS] VPC 엔드포인트 (S3 엔드포인트) [무료웹툰] 이 시국에 개인교습 쌤, 엄마한테는 비밀이예요 이 시국에 집콕 과외가 필수! 유찬은 과외 학생의 저돌적 접근이 아찔한데... 지금여기, 은밀달콤한 개인교습, 시작합니다! iryan.kr ㅇ VPC Endpoint란? > AWS 내부에서 트래픽을 주고 받기 쉽도록 설정하는 것 > S3에 접속하기 위해서는 Public망을 통해서 접근을 수행 (Public: Instance > IGW > S3 / Private: Instance > NAT > S3) > Endpoint를 통해 Instance에서 바로 S3를 향할 수 있음 ㅇ Endpoint Interface, Gateway 차이 1) Interface > Endpoint가 AZ내의 ENI로 생성하고, 해당 서비스에 대한 도메인 LookUp을 해당.. 2022. 2. 16.
반응형