Skip to content

Bump images' versions, new GQL deploy script, #1607

Open
Naramsim wants to merge 6 commits into
masterfrom
gqlupdate
Open

Bump images' versions, new GQL deploy script, #1607
Naramsim wants to merge 6 commits into
masterfrom
gqlupdate

Conversation

@Naramsim

@Naramsim Naramsim commented Jul 17, 2026

Copy link
Copy Markdown
Member

Change description

Postgres was updated to 18 from 17, and this requires a different mount point for its data. It's also required to wipe the current volume and rebuild everything. No migration will be provided.

make docker-down

AI coding assistance disclosure

Contributor check list

  • I have written a description of the contribution and explained its motivation.
  • I have written tests for my code changes (if applicable).
  • I have read and understood the AI Assisted Contribution guidelines.
  • I will own this change in production, and I am prepared to fix any bugs caused by my code change.

@Naramsim

Copy link
Copy Markdown
Member Author

@jemarq04 @FallenDeity I'm gonna merge this PR soon. I just wanted to tell you that when you will pull the changes to your local machine you will need to spin up a fresh pokeapi instance if you're using docker. Because I bumped the postgres DB version.

If you want to comment on the PR as well it's more than welcome. The aim is to deploy faster the GQL service on our small machine without building the DB on the machine but rather using a dump generated by the CICD pipeline.

Comment thread Makefile
docker compose ${gql_compose_config} stop web graphql-engine app cache
docker compose ${gql_compose_config} down -v db
docker compose ${gql_compose_config} up --pull always -d db
sleep 10

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of arbitrary sleep wouldn't it be better to check container status

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, but I don't want it to be so complicated.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking something like this

its still a one liner and kind of a simple do while loop, its more reliable too if for any reason it takes up more than the sleep alotted time

@until docker compose ${gql_compose_config} exec -T db pg_isready -U ash -d pokeapi; do sleep 1; done

similarly for the other sleep too

Comment thread Makefile Outdated
Comment thread Makefile
update-graphql-data-prod:
git pull origin master
git submodule update --remote --merge
curl -Ss -L -O https://github.com/PokeAPI/pokeapi/releases/download/master-branch/pokeapi.pgdump

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just an idea but would it be possible to stream or pipe the curl directly to pg restore over reading/writing to disk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants