Skip to content

Commit

Permalink
Container fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ardem committed Oct 16, 2024
1 parent dc6de3c commit a2404e6
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 28 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,11 @@ jobs:
- name: Build statistics
run: go build -C backend/statistics

- name: Build integrations
run: go build -C backend/integrations -buildvcs=false
#- name: Build integrations
# run: go build -C backend/integrations -buildvcs=false

- name: Build taskrunner
run: go build -C processor/taskrunner -buildvcs=false
#- name: Build taskrunner
# run: go build -C processor/taskrunner -buildvcs=false

- name: Test taskrunner
run: go test -C processor/taskrunner ./tests/... -buildvcs=false
#- name: Test taskrunner
# run: go test -C processor/taskrunner ./tests/... -buildvcs=false
24 changes: 12 additions & 12 deletions .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@ jobs:
version: v1.60
working-directory: ./backend/users
args: --timeout=5m
- name: golangci-lint for integrations
uses: golangci/golangci-lint-action@v6
with:
version: v1.60
working-directory: ./backend/integrations
args: --timeout=5m
- name: golangci-lint for taskrunner
uses: golangci/golangci-lint-action@v6
with:
version: v1.60
working-directory: ./processor/taskrunner
args: --timeout=5m
#- name: golangci-lint for integrations
# uses: golangci/golangci-lint-action@v6
# with:
# version: v1.60
# working-directory: ./backend/integrations
# args: --timeout=5m
#- name: golangci-lint for taskrunner
# uses: golangci/golangci-lint-action@v6
# with:
# version: v1.60
# working-directory: ./processor/taskrunner
# args: --timeout=5m
6 changes: 3 additions & 3 deletions backend/integrations/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
FROM golang:1.23.2-alpine AS builder
FROM public.ecr.aws/b5q6i6w4/ylem-public-images@sha256:c73b7d09874740f2c0df7003954fbbc46310ae30363e4a201d809aac5dff6afc AS builder

ENV CGO_ENABLED=0

RUN apk add --no-cache ca-certificates git curl
RUN apt-get update && apt-get install -y ca-certificates git curl

# install Golang-migrate tool
RUN curl -L https://github.com/golang-migrate/migrate/releases/download/v4.15.1/migrate.linux-amd64.tar.gz | tar xvz
Expand All @@ -23,7 +23,7 @@ COPY . .

RUN go build .

FROM golang:1.23.2-alpine AS final
FROM public.ecr.aws/b5q6i6w4/ylem-public-images@sha256:c73b7d09874740f2c0df7003954fbbc46310ae30363e4a201d809aac5dff6afc AS final

COPY --from=builder /usr/local/bin /usr/local/bin

Expand Down
1 change: 1 addition & 0 deletions backend/integrations/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ require (
github.com/Azure/azure-storage-blob-go v0.14.0 // indirect
github.com/JohnCGriffin/overflow v0.0.0-20211019200055-46fa312c352c // indirect
github.com/Shopify/sarama v1.27.0 // indirect
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9 // indirect
github.com/apache/arrow/go/arrow v0.0.0-20211013220434-5962184e7a30 // indirect
github.com/apache/arrow/go/v14 v14.0.2 // indirect
github.com/aws/aws-sdk-go-v2 v1.17.7 // indirect
Expand Down
2 changes: 2 additions & 0 deletions backend/integrations/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,8 @@ github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuy
github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0=
github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho=
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9 h1:f0LbXXOcD5fIN3hoBw3cbxy1C8rkrRi1Ul3H4KNjhTg=
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9/go.mod h1:c5eyz5amZqTKvY3ipqerFO/74a/8CYmXOahSr40c+Ww=
github.com/alexflint/go-filemutex v0.0.0-20171022225611-72bdc8eae2ae/go.mod h1:CgnQgUtFrFz9mxFNtED3jI5tLDjKlOM+oUF/sTk6ps0=
github.com/alexflint/go-filemutex v1.1.0/go.mod h1:7P4iRhttt/nUvUOrYIhcpMzv2G6CY9UnI16Z+UJqRyk=
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"context"
"database/sql"
"fmt"
//_ "github.com/alexbrainman/odbc"
_ "github.com/alexbrainman/odbc"
)

type RedshiftIntegrationConnection struct {
Expand Down
8 changes: 3 additions & 5 deletions processor/taskrunner/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
FROM golang:1.23.2-alpine AS builder
FROM public.ecr.aws/b5q6i6w4/ylem-public-images@sha256:c73b7d09874740f2c0df7003954fbbc46310ae30363e4a201d809aac5dff6afc AS builder

ENV CGO_ENABLED=0

RUN apk add --no-cache ca-certificates git curl
RUN apt-get update && apt-get install -y ca-certificates git curl

RUN mkdir /user && \
echo 'nobody:x:65534:65534:nobody:/:' > /user/passwd && \
Expand All @@ -19,7 +17,7 @@ COPY . .

RUN go build .

FROM golang:1.23.2-alpine AS final
FROM public.ecr.aws/b5q6i6w4/ylem-public-images@sha256:c73b7d09874740f2c0df7003954fbbc46310ae30363e4a201d809aac5dff6afc AS final

COPY --from=builder /user/group /user/passwd /etc/

Expand Down
1 change: 1 addition & 0 deletions processor/taskrunner/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ require (
)

require (
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9 // indirect
github.com/itchyny/timefmt-go v0.1.5 // indirect
github.com/ylem-co/es-sql-client v0.0.0-20240902163915-13ef8638db5d // indirect
github.com/ylem-co/hubspot-client v0.0.0-20240902164341-00f6a99cfdd1 // indirect
Expand Down
2 changes: 2 additions & 0 deletions processor/taskrunner/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ github.com/PaesslerAG/gval v1.1.2/go.mod h1:Fa8gfkCmUsELXgayr8sfL/sw+VzCVoa03dcO
github.com/PaesslerAG/jsonpath v0.1.0 h1:gADYeifvlqK3R3i2cR5B4DGgxLXIPb3TRTH1mGi0jPI=
github.com/PaesslerAG/jsonpath v0.1.0/go.mod h1:4BzmtoM/PI8fPO4aQGIusjGxGir2BzcV0grWtFzq1Y8=
github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw=
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9 h1:f0LbXXOcD5fIN3hoBw3cbxy1C8rkrRi1Ul3H4KNjhTg=
github.com/alexbrainman/odbc v0.0.0-20240810052813-bcbcb6842ce9/go.mod h1:c5eyz5amZqTKvY3ipqerFO/74a/8CYmXOahSr40c+Ww=
github.com/andygrunwald/go-jira v1.15.1 h1:6J9aYKb9sW8bxv3pBLYBrs0wdsFrmGI5IeTgWSKWKc8=
github.com/andygrunwald/go-jira v1.15.1/go.mod h1:GIYN1sHOIsENWUZ7B4pDeT/nxEtrZpE8l0987O67ZR8=
github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"context"
"fmt"
"database/sql"
//_ "github.com/alexbrainman/odbc"
_ "github.com/alexbrainman/odbc"
)

type RedshiftSQLIntegrationConnection struct {
Expand Down

0 comments on commit a2404e6

Please sign in to comment.