diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 3441091..542b72a 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -15,7 +15,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v4 with: - go-version: 1.22 + go-version: 1.23 - name: Install Protoc uses: arduino/setup-protoc@v1 diff --git a/.github/workflows/staging.yaml b/.github/workflows/staging.yaml index d5cd8c0..1fb6923 100644 --- a/.github/workflows/staging.yaml +++ b/.github/workflows/staging.yaml @@ -67,56 +67,62 @@ jobs: --region ${{ secrets.GKE_CLUSTER_REGION }} \ --project ${{ secrets.GKE_PROJECT_ID }} -# - name: Helm Upgrade 1 -# run: | -# helm upgrade --install ${COMPONENT} helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-mastodon-social-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) -# -# - name: Helm Upgrade 2 -# run: | -# helm upgrade --install ${COMPONENT}-infosec-exchange helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-infosec-exchange-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 3 -# run: | -# helm upgrade --install ${COMPONENT}-mstdn-social helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-mstdn-social-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 4 -# run: | -# helm upgrade --install ${COMPONENT}-botsin-space helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-botsin-space-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 5 -# run: | -# helm upgrade --install ${COMPONENT}-flipboard-social helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-flipboard-social-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 6 -# run: | -# helm upgrade --install ${COMPONENT}-mastodon-cloud helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-mastodon-cloud-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 7 -# run: | -# helm upgrade --install ${COMPONENT}-techhub-social helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-techhub-social-0.yaml \ -# --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ -# -# - name: Helm Upgrade 8 + - name: Helm Upgrade 1 + run: | + helm upgrade --install ${COMPONENT} helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-mastodon-social-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) + + - name: Helm Upgrade 2 + run: | + helm upgrade --install ${COMPONENT}-infosec-exchange helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-infosec-exchange-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 3 + run: | + helm upgrade --install ${COMPONENT}-mstdn-social helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-mstdn-social-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 4 + run: | + helm upgrade --install ${COMPONENT}-botsin-space helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-botsin-space-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 5 + run: | + helm upgrade --install ${COMPONENT}-flipboard-social helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-flipboard-social-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 6 + run: | + helm upgrade --install ${COMPONENT}-mastodon-cloud helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-mastodon-cloud-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 7 + run: | + helm upgrade --install ${COMPONENT}-techhub-social helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-techhub-social-0.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + + - name: Helm Upgrade 8 + run: | + helm upgrade --install ${COMPONENT}-mstdn-jp helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-mstdn-jp.yaml \ + --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ + +# - name: Helm Upgrade 9 # run: | -# helm upgrade --install ${COMPONENT}-mstdn-jp helm/package/${COMPONENT}-0.0.0.tgz \ -# --values helm/int-mastodon/values-mstdn-jp.yaml \ +# helm upgrade --install ${COMPONENT}-mastodon-world helm/package/${COMPONENT}-0.0.0.tgz \ +# --values helm/int-mastodon/values-mastodon-world.yaml \ # --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ - - name: Helm Upgrade 9 + - name: Helm Upgrade 10 run: | - helm upgrade --install ${COMPONENT}-mastodon-world helm/package/${COMPONENT}-0.0.0.tgz \ - --values helm/int-mastodon/values-mastodon-world.yaml \ + helm upgrade --install ${COMPONENT}-mastodon-uno helm/package/${COMPONENT}-0.0.0.tgz \ + --values helm/int-mastodon/values-mastodon-uno.yaml \ --set-string podAnnotations.commit=$(git rev-parse --short HEAD) \ diff --git a/.github/workflows/testing.yaml b/.github/workflows/testing.yaml index 199e478..e44fabe 100644 --- a/.github/workflows/testing.yaml +++ b/.github/workflows/testing.yaml @@ -17,7 +17,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v4 with: - go-version: 1.22 + go-version: 1.23 - name: Install Protoc uses: arduino/setup-protoc@v1 @@ -38,7 +38,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v4 with: - go-version: 1.22 + go-version: 1.23 - name: Install Protoc uses: arduino/setup-protoc@v1 diff --git a/Dockerfile b/Dockerfile index 8d12e1f..3009b9d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.22.5-alpine3.20 AS builder +FROM golang:1.23.0-alpine3.20 AS builder WORKDIR /go/src/int-mastodon COPY . . RUN \ diff --git a/api/grpc/client_test.go b/api/grpc/client_test.go index 6e10139..4237637 100644 --- a/api/grpc/client_test.go +++ b/api/grpc/client_test.go @@ -23,7 +23,7 @@ func TestMain(m *testing.M) { go func() { err := Serve(port, svc) if err != nil { - log.Error("", err) + log.Error(err.Error()) } }() code := m.Run() diff --git a/go.mod b/go.mod index cc67062..4ca1301 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/awakari/int-mastodon -go 1.22 +go 1.23 require ( github.com/awakari/client-sdk-go v1.1.0 diff --git a/helm/int-mastodon/templates/values-mastodon-world.yaml b/helm/int-mastodon/templates/values-mastodon-world.yaml new file mode 100644 index 0000000..56efa2f --- /dev/null +++ b/helm/int-mastodon/templates/values-mastodon-world.yaml @@ -0,0 +1,10 @@ +mastodon: + endpoint: + accounts: "https://mastodon.uno/api/v1/accounts" + search: "https://mastodon.uno/api/v2/search" + stream: "https://mastodon.uno/api/v1/streaming/public?remote=false&only_media=false" +queue: + interestsCreated: + name: "int-mastodon-mastodon-uno" + interestsUpdated: + name: "int-mastodon-mastodon-uno"