-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #26 from dsrhub/zz/refactor-migration
Refactor migrations
- Loading branch information
Showing
10 changed files
with
114 additions
and
146 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,27 @@ | ||
# ARG UTASK_IMAGE=ovhcom/utask:v1.8.1 | ||
# ARG UTASK_IMAGE=ovhcom/utask:v1.8.3 | ||
# TODO: upgrade to ovhcom/utask:v1.8.3 when it's ready | ||
ARG UTASK_IMAGE=zhouzhuojie/utask:beta-with-middleware | ||
|
||
|
||
|
||
|
||
FROM ${UTASK_IMAGE} AS builder | ||
WORKDIR /go/src/github.com/ovh/utask | ||
COPY init init | ||
COPY plugins plugins | ||
COPY pkg /go/src/github.com/dsrhub/dsrhub/pkg | ||
RUN make | ||
|
||
|
||
|
||
|
||
FROM ${UTASK_IMAGE} | ||
COPY templates /app/templates | ||
COPY --from=builder /go/src/github.com/ovh/utask/plugins /app/plugins | ||
COPY --from=builder /go/src/github.com/ovh/utask/init /app/init | ||
COPY --from=builder /go/src/github.com/ovh/utask/utask /app/utask | ||
COPY --from=builder /go/src/github.com/ovh/utask/sql /app/sql | ||
RUN go get -v github.com/rubenv/sql-migrate/... | ||
COPY ./templates /app/templates | ||
COPY ./dbconfig.yml /app/dbconfig.yml | ||
RUN chmod +x /app/utask | ||
WORKDIR /app |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
postgres: | ||
dialect: postgres | ||
datasource: ${CFG_DATABASE} | ||
dir: /app/sql/migrations |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Empty file.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.