コード例 #1
0
def billy():
    shakedown.add_user('billy', 'billy')
    shakedown.set_user_permission(rid='dcos:adminrouter:service:marathon', uid='billy', action='full')
    shakedown.set_user_permission(rid='dcos:service:marathon:marathon:services:/', uid='billy', action='full')
    yield
    shakedown.remove_user_permission(rid='dcos:adminrouter:service:marathon', uid='billy', action='full')
    shakedown.remove_user_permission(rid='dcos:service:marathon:marathon:services:/', uid='billy', action='full')
    shakedown.remove_user('billy')
コード例 #2
0
ファイル: __init__.py プロジェクト: blacklab/marathon
def user_billy():
    print("entering user_billy fixture")
    shakedown.add_user('billy', 'billy')
    shakedown.set_user_permission(rid='dcos:adminrouter:service:marathon', uid='billy', action='full')
    shakedown.set_user_permission(rid='dcos:service:marathon:marathon:services:/', uid='billy', action='full')
    yield
    shakedown.remove_user_permission(rid='dcos:adminrouter:service:marathon', uid='billy', action='full')
    shakedown.remove_user_permission(rid='dcos:service:marathon:marathon:services:/', uid='billy', action='full')
    shakedown.remove_user('billy')
    print("exiting user_billy fixture")
コード例 #3
0
def user_billy():
    print("entering user_billy fixture")
    shakedown.add_user('billy', 'billy')
    shakedown.set_user_permission(rid='dcos:adminrouter:service:marathon',
                                  uid='billy',
                                  action='full')
    shakedown.set_user_permission(
        rid='dcos:service:marathon:marathon:services:/',
        uid='billy',
        action='full')
    yield
    shakedown.remove_user_permission(rid='dcos:adminrouter:service:marathon',
                                     uid='billy',
                                     action='full')
    shakedown.remove_user_permission(
        rid='dcos:service:marathon:marathon:services:/',
        uid='billy',
        action='full')
    shakedown.remove_user('billy')
    print("exiting user_billy fixture")