Skip to content

Commit

Permalink
Merge pull request #4918 from mollykarcher/molly/master/versions
Browse files Browse the repository at this point in the history
Pinning and updating golang and ubuntu images
  • Loading branch information
mollykarcher authored Jun 22, 2023
2 parents 01c7aa3 + 38dac4e commit 34484c6
Show file tree
Hide file tree
Showing 13 changed files with 27 additions and 29 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:
jobs:
analyze:
name: Analyze
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04

strategy:
fail-fast: false
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ jobs:
complete:
if: always()
needs: [check, build, test]
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- if: contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')
run: exit 1

check:
strategy:
matrix:
os: [ubuntu-20.04]
go: [1.20.1]
os: [ubuntu-22.04]
go: ["1.20"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
Expand All @@ -37,8 +37,8 @@ jobs:
build:
strategy:
matrix:
os: [ubuntu-20.04]
go: [1.19.6, 1.20.1]
os: [ubuntu-22.04]
go: ["1.19", "1.20"]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
Expand All @@ -55,8 +55,8 @@ jobs:
test:
strategy:
matrix:
os: [ubuntu-20.04]
go: [1.19.6, 1.20.1]
os: [ubuntu-22.04]
go: ["1.19", "1.20"]
pg: [9.6.5, 10]
runs-on: ${{ matrix.os }}
services:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ permissions:

jobs:
golangci:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # version v3.0.2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/horizon-master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:

push-state-diff-image:
name: Push stellar/ledger-state-diff:{sha,latest} to DockerHub
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/horizon-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
jobs:

publish-artifacts:
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
name: Upload artifacts to GitHub release
steps:
- name: Run deprecation tests
Expand All @@ -22,7 +22,7 @@ jobs:

- uses: ./.github/actions/setup-go
with:
go-version: 1.20.1
go-version: "1.20"

- name: Check dependencies
run: ./gomod.sh
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/horizon.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ jobs:
name: Integration tests
strategy:
matrix:
os: [ubuntu-20.04]
go: [1.19.6, 1.20.1]
os: [ubuntu-20.04, ubuntu-22.04]
go: ["1.19", "1.20"]
pg: [9.6.5]
ingestion-backend: [db, captive-core, captive-core-remote-storage]
protocol-version: [19]
Expand Down Expand Up @@ -106,7 +106,7 @@ jobs:

verify-range:
name: Test (and push) verify-range image
runs-on: ubuntu-20.04
runs-on: ubuntu-22.04
env:
STELLAR_CORE_VERSION: 19.11.0-1323.7fb6d5e88.focal
CAPTIVE_CORE_STORAGE_PATH: /tmp
Expand Down
4 changes: 2 additions & 2 deletions exp/services/recoverysigner/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
FROM golang:1.19 as build
FROM golang:1.20-bullseye as build

ADD . /src/recoverysigner
WORKDIR /src/recoverysigner
RUN go build -o /bin/recoverysigner ./exp/services/recoverysigner


FROM ubuntu:20.04
FROM ubuntu:22.04

RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates
COPY --from=build /bin/recoverysigner /app/
Expand Down
4 changes: 2 additions & 2 deletions exp/services/webauth/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
FROM golang:1.19 as build
FROM golang:1.20-bullseye as build

ADD . /src/webauth
WORKDIR /src/webauth
RUN go build -o /bin/webauth ./exp/services/webauth


FROM ubuntu:20.04
FROM ubuntu:22.04

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends ca-certificates
COPY --from=build /bin/webauth /app/
Expand Down
4 changes: 2 additions & 2 deletions services/friendbot/docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
FROM golang:1.19.1 as build
FROM golang:1.20-bullseye as build

ADD . /src/friendbot
WORKDIR /src/friendbot
RUN go build -o /bin/friendbot ./services/friendbot

FROM ubuntu:20.04
FROM ubuntu:22.04

RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends ca-certificates
COPY --from=build /bin/friendbot /app/
Expand Down
4 changes: 2 additions & 2 deletions services/horizon/docker/Dockerfile.dev
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.20 AS builder
FROM golang:1.20-bullseye AS builder

ARG VERSION="devel"
WORKDIR /go/src/github.com/stellar/go
Expand All @@ -8,7 +8,7 @@ COPY . ./
ENV GOFLAGS="-ldflags=-X=github.com/stellar/go/support/app.version=${VERSION}-(built-from-source)"
RUN go install github.com/stellar/go/services/horizon

FROM ubuntu:20.04
FROM ubuntu:22.04
ARG STELLAR_CORE_VERSION
ENV STELLAR_CORE_VERSION=${STELLAR_CORE_VERSION:-*}
ENV STELLAR_CORE_BINARY_PATH /usr/bin/stellar-core
Expand Down
4 changes: 1 addition & 3 deletions services/horizon/docker/verify-range/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
FROM ubuntu:20.04

MAINTAINER Bartek Nowotarski <bartek@stellar.org>
FROM ubuntu:22.04

ARG STELLAR_CORE_VERSION
ENV STELLAR_CORE_VERSION=${STELLAR_CORE_VERSION:-*}
Expand Down
4 changes: 2 additions & 2 deletions services/horizon/docker/verify-range/start
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ fi
rm -rf "$PGDATA"/*
sudo chown -R postgres "$PGDATA"
sudo chmod -R 775 "$PGDATA"
sudo -u postgres --preserve-env=PGDATA /usr/lib/postgresql/12/bin/initdb
sudo -u postgres --preserve-env=PGDATA /usr/lib/postgresql/12/bin/pg_ctl start
sudo -u postgres --preserve-env=PGDATA /usr/lib/postgresql/14/bin/initdb
sudo -u postgres --preserve-env=PGDATA /usr/lib/postgresql/14/bin/pg_ctl start
sudo -u postgres createdb horizon
sudo -u postgres psql -c "ALTER USER postgres PASSWORD 'postgres';"

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Change to Go version used in CI or rebuild with --build-arg.
ARG GO_IMAGE=golang:1.19.1
ARG GO_IMAGE=golang:1.20-bullseye
FROM $GO_IMAGE

WORKDIR /go/src/github.com/stellar/go
Expand Down

0 comments on commit 34484c6

Please sign in to comment.