Skip to content

Commit

Permalink
Update ubuntu and golang base images
Browse files Browse the repository at this point in the history
Trying to use a more modern openssl

No longer install ruby manually

install it in docker directly

Update ruby to 3.0.2

Update ruby version

and readme

Update draupnir version and changelog

Update go and ruby images

One to use the maintainted circleci image for Golang, and the ruby one
to match the necessary ruby version
  • Loading branch information
ddumitrache committed Jul 19, 2022
1 parent de19f60 commit d4eca62
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .circleci/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Add any extra build dependencies we need for running draupnir tests
FROM circleci/golang:1.17
FROM cimg/go:1.17

RUN set -x \
&& sudo apt-get update \
Expand Down
12 changes: 3 additions & 9 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version: 2
references:
docker_golang: &docker_golang
docker:
- image: golang:1.14
- image: cimg/go:1.17
working_directory: /project

jobs:
Expand Down Expand Up @@ -37,7 +37,7 @@ jobs:
rubocop:
docker:
- image: circleci/ruby:2.7.1
- image: circleci/ruby:3.0.2
working_directory: ~/draupnir
steps:
- checkout
Expand All @@ -57,17 +57,11 @@ jobs:

integration:
machine:
image: ubuntu-2004:2022.04.2
image: ubuntu-2204:2022.04.2
steps:
- checkout
- attach_workspace:
at: workspace
- run:
name: Set Ruby version
command: |
RUBY_VERSION=$(cat .ruby-version)
rvm install $RUBY_VERSION
echo . $(rvm $RUBY_VERSION do rvm env --path) >> $BASH_ENV
- run:
name: Install Ruby bundle
command: bundle check --path=vendor/bundle || bundle install --path=vendor/bundle --jobs=4 --retry=3
Expand Down
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.7.2
3.0.2
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
ruby 2.7.2
ruby 3.0.2
golang 1.17
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
Changelog
=========

5.3.0
-----
- Update scripts to use postgres 14. Some technical changes around the versions of the tools used were also made

5.2.2
-----
- Fix order of operations when destroying instance

5.2.1
-----
- Actually bundle the drapunir-start-image script
- Actually bundle the draupnir-start-image script

5.2.0
-----
Expand Down
2 changes: 1 addition & 1 deletion DRAUPNIR_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.2.2
5.3.0
5 changes: 3 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:18.04
FROM ubuntu:22.04

ENV POSTGRESQL_VERSION=14
RUN set -x \
Expand All @@ -8,14 +8,15 @@ RUN set -x \
build-essential \
curl \
sudo \
btrfs-tools \
btrfs-progs \
&& echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main\ndeb http://apt.postgresql.org/pub/repos/apt/ $(lsb_release -cs)-pgdg 14" > /etc/apt/sources.list.d/pgdg.list \
&& curl --silent -L https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add - \
&& apt-get update -y \
&& DEBIAN_FRONTEND=noninteractive TZ=Europe/London apt-get install -y tzdata \
&& apt-get install -y \
postgresql-"${POSTGRESQL_VERSION}" \
postgresql-common \
ruby \
&& apt-get clean -y \
&& rm -rf /var/lib/apt/lists/*

Expand Down
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Development
Prerequisites:
- Go
- Postgresql
- Ruby

Create the database
```
Expand All @@ -25,6 +26,7 @@ make migrate
Development (Vagrant VM)
------------------------

**!! Disclaimer, the vagrant VM is currently unsupported on Apple Silicon**
It will often be desirable to run a full virtual machine, with btrfs, in order
to test the complete Draupnir flow. This can be achieved via the included
Vagrant configuration.
Expand Down Expand Up @@ -65,7 +67,7 @@ To run the unit tests:
make test
```

To run the integration tests:
To run the integration tests, ensure you've run `make build-linux` before running:
```
make test-integration
```
Expand Down

0 comments on commit d4eca62

Please sign in to comment.