You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
3 years ago | |
---|---|---|
deps | 3 years ago | |
perfadm | 3 years ago | |
.drone.yml | 3 years ago | |
.envrc | 3 years ago | |
.gitignore | 3 years ago | |
MANIFEST.in | 3 years ago | |
README.md | 3 years ago | |
image.nix | 3 years ago | |
pyenv.nix | 3 years ago | |
setup.py | 3 years ago | |
shell.nix | 3 years ago | |
template.yml | 3 years ago |
README.md
perfadm
Local development configuration
- Create Service Account, e.g. using
oc create sa perfadmdev
. - Set Redirect-Uri for the Service Account using
oc edit sa perfadmdev
, add the following:metadata: annotations: serviceaccounts.openshift.io/oauth-redirecturi.first: http://127.0.0.1:5000/authorize
You might need to replace
127.0.0.1:5000
based on the address your development server binds to. - Get client_secret using
oc sa get-token perfadmdev
. - Create config file (e.g.
config_dev.py
) with the following content:OC_SERVICEACCOUNT_NAMESPACE = "perfadm" # your project/namespace name, e.g. perfadm OC_SERVICEACCOUNT_NAME = "perfadm_dev" OC_OAUTH_CONFIG_URL = "https://<put-openshift-ip-here>:8443/.well-known/oauth-authorization-server" OC_CLIENT_SECRET = "<put-client-secret-here>" OC_REQUESTS_VERIFY = False SECRET_KEY = "insecure-devenv"
You might be ok with the already included
config_dev.py
. - Activate config file (e.g. by using
PERFADM_CONFIG=config_dev.py flask run
inside the perfadm directory).