Requirements

Up and Running

Assume you've just cloned the https://gitlab.com/eAuction/devops-stuff/onpremise repository, then the following steps will get you up and running in no time.

To accommodate your needs or your environment, there may need to be modifications to the included docker-compose.yml file. These instructions are a guideline for what you should generally do.

Exposed setup

  1. Create Twilio Phone Verification project and put API tokens in .env (optional - only if you want to enable notifications on the registration)

  2. Create Mailgun Email domain and put API token in .env (optional — only if you want to enable notifications on registration)

  3. Create Fixer.io Account and put API token in .env

  4. Create DNS A records for gateway, admin-panel and frontend app.

  5. Login in our Docker Registry with your gitlab.com credentials.

     docker login registry.gitlab.com
    
  6. Create env config file and fill variables.

     cp -n .env.example .env
    
  7. Create S3 bucket for storage service on AWS and IAM user with this policy -

       {
         "Version": "2012-10-17",
         "Statement": [
             {
                 "Sid": "VisualEditor0",
                 "Effect": "Allow",
                 "Action": "s3:ListBucket",
                 "Resource": [
                     "arn:aws:s3:::$BUCKET_NAME"
                 ]
             },
             {
                 "Sid": "VisualEditor1",
                 "Effect": "Allow",
                 "Action": "s3:ListAllMyBuckets",
                 "Resource": "*"
             },
             {
                 "Sid": "VisualEditor2",
                 "Effect": "Allow",
                 "Action": [
                     "s3:PutObject",
                     "s3:GetObject",
                     "s3:DeleteObject",
                     "s3:PutObjectAcl"
                 ],
                 "Resource": [
                     "arn:aws:s3:::$BUCKET_NAME/*"
                 ]
             }
         ]
     }
    

    fill variables in .env - AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_DEFAULT_REGION, STORAGE_BUCKET.

  8. Generate node secret and id, add secret to .env as NODE_SEED_SECRET.

     docker-compose run --rm --no-deps --entrypoint /stellar-core core --genseed
    
  9. Generate master secret and id, add it to .env as MASTER_SECRET and MASTER_ID.

     docker-compose run --rm --no-deps --entrypoint /stellar-core core --genseed
    
  10. Generate platform secret and id, add it to .env as PLATFORM_SECRET and PLATFORM_ID.

     docker-compose run --rm --no-deps --entrypoint /stellar-core core --genseed
    
  11. Build and tag the Docker services.

     docker-compose -f docker-compose.yml -f docker-compose.exposed.yml build
    
  12. Lift all services (detached/background mode).

     docker-compose -f docker-compose.yml -f docker-compose.exposed.yml up -d
    
  13. Create platform.

     docker-compose exec horizon /platform-init
    
  14. Access your services with created domain names.

Variables

Parameter Description Example
AWS_ACCESS_KEY_ID AWS IAM Access Key ID string
AWS_SECRET_ACCESS_KEY AWS IAM Secret Access Key string
AWS_DEFAULT_REGION AWS S3 Bucket Region us-east-2
STORAGE_BUCKET Storage Service S3 Bucket Name storage-bucket
NODE_SEED_SECRET Generated Seed Secret For Core Config File string
MASTER_SECRET Generated Seed Secret For Core Master Account string
MASTER_ID Generated Seed ID For Core Master Account string
PLATFORM_SECRET Generated Seed Secret For Horizon Platforms string
PLATFORM_ID Generated Seed ID For Horizon Platforms string
NETWORK_PASSPHRASE Core Network Passphrase Test Network ; March 2019
HISTORY_BACKEND_AWS Enable Or Disable AWS S3 Backend For Core History boolean - true/false
HISTORY_BUCKET_NAME AWS S3 Bucket Name For Core History core-hist-bucket
WEB_HOST Frontend Address (supporting IP:PORT addresses) web.test.network
ADMIN_HOST Admin-panel Address (supporting IP:PORT addresses) admin.test.network
API_HOST Api-gateway Address (supporting IP:PORT addresses) api.test.network
PLATFORM_EMAIL Email For Platform Account platform@test.network
ADMIN_EMAIL Email For Admin Account admin@test.network
ADMIN_FIRSTNAME Admin First Name string
ADMIN_LASTNAME Admin Last Name string
ADMIN_PHONE Admin Phone Number +380228822884
ADMIN_PASSWORD Admin Account Password string
SENDER_NAME Notification Sender Name (will be shown in notifications FROM field, max 11 symbols) string
SENDER_DOMAIN Mail Domain In Mailgun string
CONVERTER_API_TOKEN Fixer.io API Token string
MAILGUN_KEY Mailgun API Key string
TWILIO_SID Tilio API Sid string
TWILIO_TOKEN Tilio API Token string
CORS_ORIGINS CORS Allowed Origins To Access API-getway (optional) https://google.com,http://facebook.com
NOTIFICATION_TEMPLATE Notification Template cardeal
NEW_CORE_HIST Init Core History boolean - true/false
NEW_CORE_DB Init Core Database boolean - true/false

results matching ""

    No results matching ""