Skip to content

Commit

Permalink
updates docker image and script (#6)
Browse files Browse the repository at this point in the history
* updates docker image and script

* push images to GCR

---------

Co-authored-by: andrii.kozlov <[email protected]>
  • Loading branch information
Flaurent19 and andrii.kozlov authored Sep 21, 2023
1 parent d781ea5 commit ed33bf8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 11 deletions.
19 changes: 11 additions & 8 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
# TODO: This is a placeholder to add CI in the future
orbs:
ta-docker: travelaudience/[email protected]

version: 2.1
jobs:
build:
docker:
- image: circleci/node:4.8.2 # the primary container, where your job's commands are run
steps:
- checkout # check out the code in the project directory
- run: echo "hello world" # run the `echo` command
workflows:
docker-push:
jobs:
- ta-docker/build_and_push:
name: docker-cloudsql-goose
context: docker-registry-access
image-name: "docker-cloudsql-goose"


4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Because we intend to use this image on CircleCi, we want to use an image with a bit more components than buster
FROM golang:1.15
FROM golang:1.21

LABEL [email protected]

Expand All @@ -11,7 +11,7 @@ RUN mkdir /proxy &&\

# Fetch goose
RUN export GO111MODULE=on &&\
go get -v -u github.com/pressly/goose/cmd/goose@v2.7.0-rc5
go install github.com/pressly/goose/v3/cmd/goose@v3.15.0

RUN mkdir /db
WORKDIR /db
Expand Down
2 changes: 1 addition & 1 deletion startup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ if [[ -z "${GCLOUD_SQL_INSTANCE}" ]]; then
exit 1
fi

export GOOSE_DBSTRING=postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@localhost:${POSTGRES_PORT}/${POSTGRES_DATABASE}?sslmode=disable
export GOOSE_DBSTRING="user=${POSTGRES_USER} password=${POSTGRES_PASSWORD} dbname=${POSTGRES_DATABASE} sslmode=disable host=localhost port=${POSTGRES_PORT}"

echo "Starting the cloudsql proxy"
touch /tmp/cloudsql.log
Expand Down

0 comments on commit ed33bf8

Please sign in to comment.