Commit a6de3efe authored by Giorgos Korfiatis's avatar Giorgos Korfiatis
Browse files

cyclades: Rename service token

Rename CYCLADES_ASTAKOS_SERVICE_TOKEN to CYCLADES_SERVICE_TOKEN for
uniformity.
parent ab3a65a5
......@@ -98,7 +98,7 @@ In `/etc/synnefo/cyclades.conf` add:
CACHE_BACKEND = 'memcached://127.0.0.1:11211/'
VMAPI_BASE_URL = 'https://cyclades.example.com/'
CYCLADES_ASTAKOS_SERVICE_TOKEN = "XXXXXXXXXX"
CYCLADES_SERVICE_TOKEN = "XXXXXXXXXX"
UI_SYSTEM_IMAGES_OWNERS = {
'admin@synnefo.gr': 'system',
......
......@@ -61,6 +61,7 @@ setting was renamed to this. Therefore:
* In Cyclades settings, rename the ``APP_INSTALL_URL`` setting
to ``CYCLADES_BASE_URL``. If no such setting has been configured,
you must set it. It must point to the top-level Cyclades URL.
Rename ``CYCLADES_ASTAKOS_SERVICE_TOKEN`` to ``CYCLADES_SERVICE_TOKEN``.
* In Pithos settings, introduce a ``PITHOS_BASE_URL`` setting.
It must point to the top-level Pithos URL.
......
......@@ -108,7 +108,7 @@
## Astakos service token
## The token used for astakos service api calls (e.g. api to retrieve user email
## using a user uuid)
#CYCLADES_ASTAKOS_SERVICE_TOKEN = ''
#CYCLADES_SERVICE_TOKEN = ''
# Let cyclades proxy user specific api calls to astakos, via self served
# endpoints. Set this to False if you deploy cyclades-app/astakos-app on the
......
......@@ -52,11 +52,11 @@ def warn(*msgs):
print "WARNING: %s" % ' '.join(msgs)
get_displayname = functools.partial(astakos.get_displayname,
settings.CYCLADES_ASTAKOS_SERVICE_TOKEN,
settings.CYCLADES_SERVICE_TOKEN,
url=settings.ASTAKOS_URL.replace('im/authenticate',
'service/api/user_catalogs'))
get_user_uuid = functools.partial(astakos.get_user_uuid,
settings.CYCLADES_ASTAKOS_SERVICE_TOKEN,
settings.CYCLADES_SERVICE_TOKEN,
url=settings.ASTAKOS_URL.replace('im/authenticate',
'service/api/user_catalogs'))
......
......@@ -35,7 +35,7 @@ from optparse import make_option
from synnefo.webproject.management.commands import ListCommand
from synnefo.db.models import Network
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
from logging import getLogger
......
......@@ -40,7 +40,7 @@ from snf_django.lib.astakos import UserCache
from synnefo.logic.rapi import GanetiApiError
from synnefo.management.common import Omit
from synnefo.management import common
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
......
......@@ -37,7 +37,7 @@ from synnefo.webproject.management.commands import ListCommand
from synnefo.db.models import VirtualMachine
from synnefo.management.common import get_backend
from synnefo.api.util import get_image
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
from logging import getLogger
log = getLogger(__name__)
......
......@@ -36,7 +36,7 @@ from synnefo.webproject.management.commands import SynnefoCommand
from synnefo.management.common import (format_vm_state, get_vm,
get_image)
from snf_django.lib.astakos import UserCache
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
from synnefo.webproject.management import utils
......
......@@ -108,7 +108,7 @@ SECRET_ENCRYPTION_KEY = "Password Encryption Key"
# Astakos service token
# The token used for astakos service api calls (e.g. api to retrieve user email
# using a user uuid)
CYCLADES_ASTAKOS_SERVICE_TOKEN = ''
CYCLADES_SERVICE_TOKEN = ''
# Let cyclades proxy user specific api calls to astakos, via self served
# endpoints. Set this to False if you deploy cyclades-app/astakos-app on the
......
......@@ -42,7 +42,7 @@ from synnefo.db.models import (Backend, BackendNetwork,
pooled_rapi_client)
from synnefo.logic.rapi import GanetiApiError
from snf_django.lib.astakos import UserCache
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
from util import pool_map_chunks
......
......@@ -77,7 +77,7 @@ _pithos_backend_pool = \
PithosBackendPool(
POOL_SIZE,
astakos_url=settings.ASTAKOS_BASE_URL,
service_token=settings.CYCLADES_ASTAKOS_SERVICE_TOKEN,
service_token=settings.CYCLADES_SERVICE_TOKEN,
astakosclient_poolsize=settings.ASTAKOS_POOLSIZE,
db_connection=settings.BACKEND_DB_CONNECTION,
block_path=settings.BACKEND_BLOCK_PATH)
......
......@@ -33,7 +33,7 @@ from django.db import transaction
from snf_django.lib.api import faults
from synnefo.db.models import QuotaHolderSerial, VirtualMachine, Network
from synnefo.settings import (CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN,
from synnefo.settings import (CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN,
ASTAKOS_BASE_URL)
from astakosclient import AstakosClient
from astakosclient.errors import AstakosClientException, QuotaLimit
......
......@@ -39,7 +39,7 @@ from synnefo import quotas
from synnefo.quotas.util import (get_db_holdings, get_quotaholder_holdings,
transform_quotas)
from synnefo.webproject.management.utils import pprint_table
from synnefo.settings import CYCLADES_ASTAKOS_SERVICE_TOKEN as ASTAKOS_TOKEN
from synnefo.settings import CYCLADES_SERVICE_TOKEN as ASTAKOS_TOKEN
class Command(BaseCommand):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment