Files
houston-be/Makefile

84 lines
5.4 KiB
Makefile
Raw Normal View History

TP-44162 | Google Meet integration to create calendar invite with meeting link creation on incident creation (#277) * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-48200 | updated response messages in link and unlink jira apis (#278) * TP-44162 | resolved review comments * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-44162 | resolved review comments * TP-44162 | updated few naming conventions * TP-44162 | Adding timeouts to google drive api calls and related UTs * TP-44162 | Adding drive api timeout to viper for unit test --------- Co-authored-by: Sriram Bhargav <sriram.bhargav@navi.com> Co-authored-by: Shashank Shekhar <shashank.shekhar@navi.com>
2023-11-09 16:25:20 +05:30
.PHONY: docker-run
docker-run: docker-build
docker run houston
2023-03-29 20:57:20 +05:30
2023-06-14 12:45:13 +05:30
.PHONY: docker-build
2023-03-29 20:57:20 +05:30
docker-build:
2023-04-12 00:14:47 +05:30
docker build -t houston -f Dockerfile.houston .
2023-03-29 20:57:20 +05:30
2023-06-14 12:45:13 +05:30
.PHONY: migration-up
2023-04-12 00:14:47 +05:30
migration-up:
2023-10-16 19:39:56 +05:30
migrate -path db/migration/ -database "${POSTGRES_DSN}?sslmode=disable" -verbose up
2023-04-12 00:14:47 +05:30
2023-06-14 12:45:13 +05:30
.PHONY: migration-down
2023-04-12 00:14:47 +05:30
migration-down:
migrate -path db/migration/ -database "${POSTGRES_DSN}?sslmode=disable" -verbose down
TP-44162 | Google Meet integration to create calendar invite with meeting link creation on incident creation (#277) * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-48200 | updated response messages in link and unlink jira apis (#278) * TP-44162 | resolved review comments * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-44162 | resolved review comments * TP-44162 | updated few naming conventions * TP-44162 | Adding timeouts to google drive api calls and related UTs * TP-44162 | Adding drive api timeout to viper for unit test --------- Co-authored-by: Sriram Bhargav <sriram.bhargav@navi.com> Co-authored-by: Shashank Shekhar <shashank.shekhar@navi.com>
2023-11-09 16:25:20 +05:30
.PHONY: build
build: test
go mod tidy && CGO_ENABLED=0 go build -ldflags="-s -w" -o houston cmd/main.go
.PHONY: test
test: generatemocks
go test -v -count=1 $(CURDIR)/service/...
go test -v -count=1 $(CURDIR)/pkg/...
go test -v -count=1 $(CURDIR)/common/...
TP-44162 | Google Meet integration to create calendar invite with meeting link creation on incident creation (#277) * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-48200 | updated response messages in link and unlink jira apis (#278) * TP-44162 | resolved review comments * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-44162 | resolved review comments * TP-44162 | updated few naming conventions * TP-44162 | Adding timeouts to google drive api calls and related UTs * TP-44162 | Adding drive api timeout to viper for unit test --------- Co-authored-by: Sriram Bhargav <sriram.bhargav@navi.com> Co-authored-by: Shashank Shekhar <shashank.shekhar@navi.com>
2023-11-09 16:25:20 +05:30
@rm -rf $(CURDIR)/mocks
# Keep all mock file generation below this line
.PHONY: generatemocks
generatemocks:
@go install github.com/gojuno/minimock/v3/cmd/minimock@v3.1.3
@go mod tidy
@rm -rf $(CURDIR)/mocks
@echo "Generating mocks..."
@mkdir "mocks"
cd $(CURDIR)/pkg/google/googleDrive && minimock -i DriveActions -s _mock.go -o $(CURDIR)/mocks
TP-44162 | Google Meet integration to create calendar invite with meeting link creation on incident creation (#277) * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-48200 | updated response messages in link and unlink jira apis (#278) * TP-44162 | resolved review comments * TP-44158 | Adding service to get transcript files from Google Drive (#234) Adding service to get transcript files from Google Drive * TP-45120 (#275) TP-45120 | merging Google auth implementation and calendar event fix * TP-44162 | added service implementation for calendar actions * TP-44162 | Updated label in slack message * TP-44162 | Fixed build failures * TP-44162 | Updated sql migration file name * TP-44162 | added unit tests for google calendar service * TP-44162 | resolved review comments * TP-44162 | updated few naming conventions * TP-44162 | Adding timeouts to google drive api calls and related UTs * TP-44162 | Adding drive api timeout to viper for unit test --------- Co-authored-by: Sriram Bhargav <sriram.bhargav@navi.com> Co-authored-by: Shashank Shekhar <shashank.shekhar@navi.com>
2023-11-09 16:25:20 +05:30
cd $(CURDIR)/pkg/conference && minimock -i ICalendarActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/rest/ && minimock -i HttpRestClient -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/atlassian/ && minimock -i JiraClient -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/slack && minimock -i ISlackService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/incident && minimock -i IIncidentService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/rca && minimock -i IRcaRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/incident && minimock -i IIncidentRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/monitoringService && minimock -i MonitoringServiceActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/incident && minimock -i IIncidentRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/monitoringService && minimock -i ServiceActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/monitoringService && minimock -i MonitoringServiceActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/common/util/channel && minimock -i IChannelUtil -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/incident_channel && minimock -i IIncidentChannelService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/team && minimock -i ITeamRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/severity && minimock -i ISeverityRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/user && minimock -i IUserRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/documentService && minimock -i ServiceActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/rcaInput && minimock -i IRcaInputRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/teamService && minimock -i ITeamServiceV2 -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/user && minimock -i IUserRepositoryInterface -s _mock.go -o $(CURDIR)/mocks
TP-48512 | Implementation of RCA and tag migration (#296) * TP-38709 | Merging the changes to master on the logfix * TP-48512 | Added button element for RCA section and implemented fill rca details * TP-48512 | Small fixes * TP-48512 | adding unit tests * TP-48512 | added unit tests * TP-48512 | updated color code for rca card * TP-48512 | Removed duplicate interface * TP-48512 | Added one more unit test * TP-48512 | added comments for jira link validation and update * TP-48512 | Merging the changes to master on the logfix # Conflicts: # cmd/app/handler/slack_handler.go * TP-48512 | Added button element for RCA section and implemented fill rca details # Conflicts: # common/util/common_util.go # common/util/constant.go # internal/processor/action/incident_resolve_action.go # internal/processor/action/incident_update_jira-links_action.go # internal/processor/action/incident_update_resolution_text_action.go # internal/processor/action/view/incident_resolution_text.go # internal/processor/action/view/incident_section.go # service/slack/slack_service.go * TP-48512 | Small fixes * TP-48512 | adding unit tests * TP-48512 | added unit tests # Conflicts: # Makefile # service/incident/incident_service_v2_interface.go * TP-48512 | updated color code for rca card * TP-48512 | Removed duplicate interface * TP-48512 | Added one more unit test * TP-48512 | added comments for jira link validation and update * TP-48512 | Fixed merge conflicts * TP-48512 | Fixed merge conflicts * TP-48512 | Fixed merge conflicts * TP-48512 | Added sql migration script for adding tags * TP-48512 | Updated sql migration script for adding tags * TP-48512 | Fixed merge conflicts and updated tags in sql migration script
2023-12-07 14:13:12 +05:30
cd $(CURDIR)/model/tag && minimock -i ITagRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/incident && minimock -i IIncidentRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/monitoringService && minimock -i MonitoringServiceActions -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/krakatoa && minimock -i IKrakatoaService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/socketModeClient && minimock -i ISocketModeClientWrapper -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/maverick && minimock -i IMaverickClient -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/incident_jira && minimock -i IncidentJiraService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/incident_jira && minimock -i IncidentJiraRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/product && minimock -i ProductRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/products_teams && minimock -i ProductsTeamsRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/model/incident_products && minimock -i IncidentProductsRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/google && minimock -i IDriveService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/rca && minimock -i IRcaService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/pkg/alertClient && minimock -i AlertClient -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/externalTeamRepo && minimock -i IExternalTeamRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/alertService && minimock -i IAlertService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/tag && minimock -i ITagService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/conference && minimock -i ICalendarService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/severity && minimock -i ISeverityService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/user && minimock -i UserService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/teamSeverity && minimock -i ITeamSeverityService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/teamUser && minimock -i ITeamUserService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/teamUserSeverity && minimock -i ITeamUserSeverityService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/service/productsTeams && minimock -i ProductTeamsService -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/teamSeverity && minimock -i TeamSeverityRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/teamUser && minimock -i TeamUserRepository -s _mock.go -o $(CURDIR)/mocks
cd $(CURDIR)/repository/teamUserSeverity && minimock -i TeamUserSeverityRepository -s _mock.go -o $(CURDIR)/mocks