This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CodeDeploy 버전 (테스트 모드 : 0.0 ) | |
version: 0.0 | |
# 배포할 서버의 운영체제 | |
os: linux | |
files: | |
- source: / # CodeDeploy에서 전달해 준 파일 중 destination으로 이동시킬 대상을 지정 (루트 경로 : 전체 파일) | |
destination: /home/ec2-user/app/deploy/zip/ # source에서 지정된 파일을 받을 위치 | |
overwrite: yes # 기존 파일들을 덮어 쓰기 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CodeDeploy 버전 (테스트 모드 : 0.0 ) | |
version: 0.0 | |
# 배포할 서버의 운영체제 | |
os: linux | |
files: | |
- source: / # CodeDeploy에서 전달해 준 파일 중 destination으로 이동시킬 대상을 지정 (루트 경로 : 전체 파일) | |
destination: /home/ec2-user/app/deploy/zip/ # source에서 지정된 파일을 받을 위치 | |
overwrite: yes # 기존 파일들을 덮어 쓰기 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require("express"); | |
const app = express(); | |
const AWS = require("aws-sdk"); | |
const credentials = new AWS.SharedIniFileCredentials({profile: "default",}); | |
const sns = new AWS.SNS({ credentials: credentials, region: "ap-northeast-2" }); | |
const port = 3000; | |
app.use(express.json()); | |
app.get("/status", (req, res) => res.json({ status: "ok", sns: sns })); | |
app.post("/send", (req, res) => { |