#author("2019-03-18T13:13:43+00:00","","") #mynavi(AWSメモ) #setlinebreak(on); * 目次 [#d56f3755] #contents - 関連 -- [[AWS CloudFormationメモ]] -- [[独自ドメイン名で API Gateway または EC2にアクセスする]] -- [[カスタムドメインを使用して API Gateway をデプロイする]] * AWS::Serverless 変換を利用する場合 [#xf928cdf] #html(<div style="padding-left: 10px;">) template.yml #mycode2(){{ AWSTemplateFormatVersion : '2010-09-09' Transform: AWS::Serverless-2016-10-31 Description: Test serverless application. Resources: SampleApi: Type: AWS::Serverless::Function Properties: FunctionName: SampleFunction Description: "Sample" Handler: index.handler Runtime: python3.6 Events: ListApi: Type: Api Properties: Path: / Method: get GetApi: Type: Api Properties: Path: /{id} Method: get Outputs: SampleApiUri: # 作成したAPIのURIをエクスポートしておく # ※AWS::Serverless変換を使用した場合、ステージは Stage,Prod の2つが作成される Description: "API Gateway endpoint URL for Prod stage" Value: !Sub "https://${ServerlessRestApi}.execute-api.${AWS::Region}.amazonaws.com/Prod/" Export: Name: SampleApiUri }} ※実際の運用ではカスタムドメインを使用してベースパスマッピングを設定する事になるが、ここでは割愛する。 #html(</div>) * AWS::Serverless 変換を利用しない場合 [#ee3de6bf] #html(<div style="padding-left: 10px;">) #TODO #html(</div>)