Skip to content

Commit

Permalink
docker: upgrade to 0.5.7 (cadence-workflow#1819)
Browse files Browse the repository at this point in the history
  • Loading branch information
venkat1109 authored May 9, 2019
1 parent 0fb7513 commit 686fa47
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 6 deletions.
1 change: 1 addition & 0 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ COPY ./config_template_mysql.yaml $CADENCE_HOME/config/docker_template_mysql.yam
RUN chmod a+x $CADENCE_HOME/start.sh

COPY --from=builder /go/src/github.com/uber/cadence/cadence-cassandra-tool /cadence
COPY --from=builder /go/src/github.com/uber/cadence/cadence-sql-tool /cadence
COPY --from=builder /go/src/github.com/uber/cadence/cadence /cadence
COPY --from=builder /go/src/github.com/uber/cadence/cadence-server /cadence
COPY --from=builder /go/src/github.com/uber/cadence/schema/ /cadence/schema/
Expand Down
3 changes: 3 additions & 0 deletions docker/config_template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,3 +94,6 @@ archival:
- name: "custom-bucket-2"
owner: "custom-owner-2"
retentionDays: 5

publicClient:
hostPort: ${BIND_ON_IP}:7933
3 changes: 3 additions & 0 deletions docker/config_template_mysql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,6 @@ archival:
- name: "custom-bucket-2"
owner: "custom-owner-2"
retentionDays: 5

publicClient:
hostPort: ${BIND_ON_IP}:7933
2 changes: 1 addition & 1 deletion docker/docker-compose-mysql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ services:
- "8125:8125"
- "8126:8126"
cadence:
image: ubercadence/server:0.5.6
image: ubercadence/server:0.5.7
ports:
- "7933:7933"
- "7934:7934"
Expand Down
2 changes: 1 addition & 1 deletion docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ services:
- "8125:8125"
- "8126:8126"
cadence:
image: ubercadence/server:0.5.6
image: ubercadence/server:0.5.7
ports:
- "7933:7933"
- "7934:7934"
Expand Down
12 changes: 8 additions & 4 deletions docker/start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,14 @@ setup_cassandra_schema() {
}

setup_mysql_schema() {
mysql -h $MYSQL_SEEDS -u$MYSQL_USER -p$MYSQL_PWD < $CADENCE_HOME/schema/mysql/v57/cadence/database.sql
mysql -h $MYSQL_SEEDS -u$MYSQL_USER -p$MYSQL_PWD $DBNAME < $CADENCE_HOME/schema/mysql/v57/cadence/schema.sql
mysql -h $MYSQL_SEEDS -u$MYSQL_USER -p$MYSQL_PWD < $CADENCE_HOME/schema/mysql/v57/visibility/database.sql
mysql -h $MYSQL_SEEDS -u$MYSQL_USER -p$MYSQL_PWD $VISIBILITY_DBNAME < $CADENCE_HOME/schema/mysql/v57/visibility/schema.sql
SCHEMA_DIR=$CADENCE_HOME/schema/mysql/v57/cadence/versioned
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD create --db $DBNAME
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD --db $DBNAME setup-schema -v 0.0
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD --db $DBNAME update-schema -d $SCHEMA_DIR
VISIBILITY_SCHEMA_DIR=$CADENCE_HOME/schema/mysql/v57/visibility/versioned
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD create --db $VISIBILITY_DBNAME
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD --db $VISIBILITY_DBNAME setup-schema -v 0.0
$CADENCE_HOME/cadence-sql-tool --ep $MYSQL_SEEDS -u $MYSQL_USER --pw $MYSQL_PWD --db $VISIBILITY_DBNAME update-schema -d $VISIBILITY_SCHEMA_DIR
}

setup_schema() {
Expand Down

0 comments on commit 686fa47

Please sign in to comment.