Skip to content

Commit

Permalink
credentials template for better reuse (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
vaclavdobsicek authored Sep 24, 2024
1 parent 177da2c commit cce1744
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,10 @@ When updating, you can:
<span style="color:#004795"> **Initialize empty project and repository** </span>

1. Run `prd init <project_name>` which will initialize an empty GIT repository. You can also use `.` for the project name and use the current directory.
2. Fill in the required credentials in the `credentials.json` file that was created in the project folder - either `source.token` (retrieved using /auth endpoint) or `source.username` and `source.password`.
3. Fill in `source_api_base` in the `prd_config.yaml` file.
4. If you are going to deploy the code to a different Rossum organization configure `target_api_base` and `use_same_org_as_target: false` in `prd_config.yaml` and either `target.token` or `target.username` and `target.password` in `credentials.json`.
2. Copy `credentials.template.json` to `credentials.json`
3. Fill in the required credentials in the `credentials.json` file that was created in the project folder - either `source.token` (retrieved using /auth endpoint) or `source.username` and `source.password`.
4. Fill in `source_api_base` in the `prd_config.yaml` file.
5. If you are going to deploy the code to a different Rossum organization configure `target_api_base` and `use_same_org_as_target: false` in `prd_config.yaml` and either `target.token` or `target.username` and `target.password` in `credentials.json`.

> ℹ️ This command creates local git repository. If you want to connect it to an existing remote repository, call `git remote add <reponame> <giturl>`. If you already have an existing remote repository, it might be easier to clone it from the remote and create an `credentials.json` file manually in the root folder.
Expand Down
2 changes: 1 addition & 1 deletion project_rossum_deploy/commands/initialize.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def init_project(name: Path):
with open(name / ".gitignore", "a") as wf:
wf.write(credentials_ignore_line)

credentials_path = name / "credentials.json"
credentials_path = name / "credentials.template.json"
copy_dummy_credentials_file(credentials_path)

config_path = name / "prd_config.yaml"
Expand Down

0 comments on commit cce1744

Please sign in to comment.