Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
hivemind
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
hive
hivemind
Commits
fe72f1fb
Commit
fe72f1fb
authored
4 years ago
by
Bartek Wrona
Browse files
Options
Downloads
Patches
Plain Diff
Update .gitlab-ci.yaml
parent
37d1868e
No related branches found
No related tags found
4 merge requests
!456
Release candidate v1 24
,
!230
Setup monitoring with pghero
,
!135
Enable postgres monitoring on CI server
,
!38
Hivemind ci separate sync
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yaml
+8
-5
8 additions, 5 deletions
.gitlab-ci.yaml
with
8 additions
and
5 deletions
.gitlab-ci.yaml
+
8
−
5
View file @
fe72f1fb
...
@@ -12,7 +12,7 @@ variables:
...
@@ -12,7 +12,7 @@ variables:
GIT_STRATEGY
:
clone
GIT_STRATEGY
:
clone
GIT_SUBMODULE_STRATEGY
:
recursive
GIT_SUBMODULE_STRATEGY
:
recursive
HIVEMIND_SOURCE_HIVED_URL
:
$HIVEMIND_SOURCE_HIVED_URL
HIVEMIND_SOURCE_HIVED_URL
:
$HIVEMIND_SOURCE_HIVED_URL
HIVEMIND_DB_NAME
:
"
${
hive_$CI_COMMIT_REF_SLUG
/-/_}
"
HIVEMIND_DB_NAME
:
"
hive_$CI_COMMIT_REF_SLUG"
HIVEMIND_HTTP_PORT
:
$HIVEMIND_HTTP_PORT
HIVEMIND_HTTP_PORT
:
$HIVEMIND_HTTP_PORT
# Configured at gitlab repository settings side
# Configured at gitlab repository settings side
POSTGRES_USER
:
$HIVEMIND_POSTGRES_USER
POSTGRES_USER
:
$HIVEMIND_POSTGRES_USER
...
@@ -20,7 +20,6 @@ variables:
...
@@ -20,7 +20,6 @@ variables:
POSTGRES_HOST_AUTH_METHOD
:
trust
POSTGRES_HOST_AUTH_METHOD
:
trust
# official way to provide password to psql: http://www.postgresql.org/docs/9.3/static/libpq-envars.html
# official way to provide password to psql: http://www.postgresql.org/docs/9.3/static/libpq-envars.html
PGPASSWORD
:
$HIVEMIND_POSTGRES_PASSWORD
PGPASSWORD
:
$HIVEMIND_POSTGRES_PASSWORD
DB_URL
:
"
$HIVEMIND_POSTGRESQL_CONNECTION_STRING/$HIVEMIND_DB_NAME"
PYTHONUSERBASE
:
./local-site
PYTHONUSERBASE
:
./local-site
...
@@ -60,14 +59,18 @@ hivemind_sync:
...
@@ -60,14 +59,18 @@ hivemind_sync:
HIVEMIND_MAX_BLOCK
:
50000
HIVEMIND_MAX_BLOCK
:
50000
script
:
script
:
-
DB_NAME=${HIVEMIND_DB_NAME/-/_}
-
DB_URL="$HIVEMIND_POSTGRESQL_CONNECTION_STRING/$HIVEMIND_DB_NAME"
-
echo "Corrected db name
:
$DB_NAME"
-
echo "Corrected db url
:
$DB_URL"
-
ls -l dist/*
-
ls -l dist/*
-
rm -rf ./local-site
-
rm -rf ./local-site
-
mkdir -p `python3 -m site --user-site`
-
mkdir -p `python3 -m site --user-site`
-
python3 setup.py install --user --force
-
python3 setup.py install --user --force
-
./local-site/bin/hive -h
-
./local-site/bin/hive -h
-
"
echo
Attempting
to
recreate
database
$
HIVEMIND_
DB_NAME"
-
"
echo
Attempting
to
recreate
database
$DB_NAME"
-
psql -U $POSTGRES_USER -h localhost -d postgres -c "DROP DATABASE IF EXISTS $
HIVEMIND_
DB_NAME;"
-
psql -U $POSTGRES_USER -h localhost -d postgres -c "DROP DATABASE IF EXISTS $DB_NAME;"
-
psql -U $POSTGRES_USER -h localhost -d postgres -c "CREATE DATABASE $
HIVEMIND_
DB_NAME;"
-
psql -U $POSTGRES_USER -h localhost -d postgres -c "CREATE DATABASE $DB_NAME;"
-
"
echo
Attempting
to
starting
hive
sync
using
hived
node:
$HIVEMIND_SOURCE_HIVED_URL
.
Max
sync
block
is:
$HIVEMIND_MAX_BLOCK"
-
"
echo
Attempting
to
starting
hive
sync
using
hived
node:
$HIVEMIND_SOURCE_HIVED_URL
.
Max
sync
block
is:
$HIVEMIND_MAX_BLOCK"
-
echo Attempting to access database $DB_URL
-
echo Attempting to access database $DB_URL
-
./local-site/bin/hive sync --test-max-block=$HIVEMIND_MAX_BLOCK --exit-after-sync --test-profile=False --steemd-url "$HIVEMIND_SOURCE_HIVED_URL" --database-url $DB_URL 2>&1 | tee -i hivemind-sync.log
-
./local-site/bin/hive sync --test-max-block=$HIVEMIND_MAX_BLOCK --exit-after-sync --test-profile=False --steemd-url "$HIVEMIND_SOURCE_HIVED_URL" --database-url $DB_URL 2>&1 | tee -i hivemind-sync.log
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment