operations: Update root Makefile to correctly deploy the API.
This commit is contained in:
		
							
								
								
									
										3
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										3
									
								
								Makefile
									
									
									
									
									
								
							@@ -23,8 +23,7 @@ dist/hff-entry-forms-web-${VERSION}.${TARGET_ENV}.tar.gz:
 | 
				
			|||||||
	tar czf dist/hff-entry-forms-web-${VERSION}.${TARGET_ENV}.tar.gz -C web/dist .
 | 
						tar czf dist/hff-entry-forms-web-${VERSION}.${TARGET_ENV}.tar.gz -C web/dist .
 | 
				
			||||||
 | 
					
 | 
				
			||||||
deploy-api:
 | 
					deploy-api:
 | 
				
			||||||
	make -C api build-image push-image
 | 
						TARGET_ENV=${TARGET_ENV} make -C api build-image push-image publish
 | 
				
			||||||
	cd operations/terraform && terraform apply -target module.${TARGET_ENV}_env.aws_ecs_task_definition.hff_entry_forms_api -target module.${TARGET_ENV}_env.aws_ecs_service.hff_entry_forms_api
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
deploy-web: dist/hff-entry-forms-web-${VERSION}.${TARGET_ENV}.tar.gz
 | 
					deploy-web: dist/hff-entry-forms-web-${VERSION}.${TARGET_ENV}.tar.gz
 | 
				
			||||||
	mkdir -p temp-deploy/hff-entry-forms-web-${VERSION}
 | 
						mkdir -p temp-deploy/hff-entry-forms-web-${VERSION}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -4,7 +4,7 @@ import hff_entry_forms_apipkg/models
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
suite "models":
 | 
					suite "models":
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  test "asNotionPage(EventProposal)":
 | 
					  test "toPage(EventProposal)":
 | 
				
			||||||
    let ep = EventProposal(
 | 
					    let ep = EventProposal(
 | 
				
			||||||
      name: "Test Event",
 | 
					      name: "Test Event",
 | 
				
			||||||
      description: "A test event.",
 | 
					      description: "A test event.",
 | 
				
			||||||
@@ -15,6 +15,6 @@ suite "models":
 | 
				
			|||||||
      date: parse("2021-10-30", "YYYY-MM-dd"),
 | 
					      date: parse("2021-10-30", "YYYY-MM-dd"),
 | 
				
			||||||
      budgetInDollars: 56)
 | 
					      budgetInDollars: 56)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    let expectedJson = """{"properties":{"Event":{"title":[{"type":"text","text":{"content":"Test Event"}}]},"Date":{"date":{"start":"2021-10-30T00:00:00.000-05:00"}},"Department":{"multi_select":[{"name":"Testing"}]},"Location":{"rich_text":[{"type":"text","text":{"content":"Hope Family Fellowship"}}]},"Owner":{"rich_text":[{"type":"text","text":{"content":"Jonathan Bernard"}}]},"State":{"select":{"name":"Proposed"}},"Visibility":{"select":{"name":"Public"}}},"children":[{"object":"block","type":"heading_2","heading_2":{"text":[{"type":"text","text":{"content":"Purpose"}}]}},{"object":"block","type":"paragraph","paragraph":{"text":[{"type":"text","text":{"content":"Event example for unit testing."}}]}},{"object":"block","type":"heading_2","heading_2":{"text":[{"type":"text","text":{"content":"Description"}}]}},{"object":"block","type":"paragraph","paragraph":{"text":[{"type":"text","text":{"content":"A test event."}}]}}]}"""
 | 
					    let expectedJson = """{"properties":{"Event":{"title":[{"type":"text","text":{"content":"Test Event"}}]},"Date":{"date":{"start":"2021-10-30T00:00:00-05:00"}},"Department":{"multi_select":[{"name":"Testing"}]},"Location":{"rich_text":[{"type":"text","text":{"content":"Hope Family Fellowship"}}]},"Owner":{"rich_text":[{"type":"text","text":{"content":"Jonathan Bernard"}}]},"State":{"select":{"name":"Proposed"}},"Visibility":{"select":{"name":"Public"}}},"children":[{"object":"block","type":"heading_2","heading_2":{"text":[{"type":"text","text":{"content":"Purpose"}}]}},{"object":"block","type":"paragraph","paragraph":{"text":[{"type":"text","text":{"content":"Event example for unit testing."}}]}},{"object":"block","type":"heading_2","heading_2":{"text":[{"type":"text","text":{"content":"Description"}}]}},{"object":"block","type":"paragraph","paragraph":{"text":[{"type":"text","text":{"content":"A test event."}}]}}]}"""
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    check $(ep.asNotionPage) == expectedJson
 | 
					    check $(ep.toPage) == expectedJson
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user