.
This commit is contained in:
parent
ef4dddd64b
commit
2e656c1651
5 changed files with 11 additions and 5 deletions
|
|
@ -5,7 +5,7 @@ RUN go mod tidy
|
|||
RUN CGO_ENABLED=0 go build -o app .
|
||||
|
||||
FROM alpine:3.14
|
||||
LABEL org.opencontainers.image.source https://github.com/trstringer/manual-approval
|
||||
LABEL org.opencontainers.image.source https://github.com/snskArora/manual-approval
|
||||
RUN apk update && apk add ca-certificates
|
||||
COPY --from=builder /var/app/app /var/app/app
|
||||
CMD ["/var/app/app"]
|
||||
|
|
|
|||
4
Makefile
4
Makefile
|
|
@ -1,5 +1,5 @@
|
|||
IMAGE_REPO=ghcr.io/trstringer/manual-approval
|
||||
TARGET_PLATFORM=linux/amd64
|
||||
IMAGE_REPO ?= ghcr.io/snskArora/manual-approval
|
||||
TARGET_PLATFORM ?= linux/amd64
|
||||
|
||||
.PHONY: tidy
|
||||
tidy:
|
||||
|
|
|
|||
|
|
@ -50,4 +50,4 @@ outputs:
|
|||
description: The status of the approval ("approved" or "denied")
|
||||
runs:
|
||||
using: docker
|
||||
image: docker://ghcr.io/trstringer/manual-approval:1.9.1
|
||||
image: docker://ghcr.io/sunny-1651/manual-approval:latest
|
||||
|
|
|
|||
|
|
@ -109,6 +109,12 @@ func (a *approvalEnvironment) createApprovalIssue(ctx context.Context) error {
|
|||
}
|
||||
a.approvalIssueNumber = a.approvalIssue.GetNumber()
|
||||
|
||||
// Now add a comment to the same issue
|
||||
commentBody := "This is a comment on the issue."
|
||||
_, _, err = a.client.Issues.CreateComment(ctx, a.targetRepoOwner, a.targetRepoName, *a.approvalIssue.Number, &github.IssueComment{
|
||||
Body: &commentBody,
|
||||
})
|
||||
|
||||
fmt.Printf("Issue created: %s\n", a.approvalIssue.GetHTMLURL())
|
||||
return nil
|
||||
}
|
||||
|
|
|
|||
2
go.mod
2
go.mod
|
|
@ -1,4 +1,4 @@
|
|||
module github.com/trstringer/manual-approval
|
||||
module github.com/snskArora/manual-approval
|
||||
|
||||
go 1.17
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue