Skip to content

Commit

Permalink
feat(basemaps): Update the standardise workflow and create-config wor…
Browse files Browse the repository at this point in the history
…kflow to use cogify create-config (#182)

#### Description
Update the standerise workflow and create-config workflow to use cogify
create-config


#### Intention
Updated standerise workflow and create-config workflow.
Update standerise workflow basemaps/cli version default to v6.



#### Checklist
- [ ] Tests updated
- [ ] Docs updated
- [ ] Issue linked in Title

---------

Co-authored-by: Alice Fage <afage@linz.govt.nz>
  • Loading branch information
Wentao-Kuang and amfage authored Oct 3, 2023
1 parent 8509a1e commit 9b8942d
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 29 deletions.
29 changes: 15 additions & 14 deletions workflows/basemaps/create-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ spec:
entrypoint: main
arguments:
parameters:
- name: version-basemaps-cli
- name: version_basemaps_cli
value: "v6"
- name: location
value: "s3://bucket/path/to"
Expand All @@ -26,27 +26,28 @@ spec:
- name: location
value: "{{workflow.parameters.location}}"
- name: create-config
retryStrategy:
limit: "2"
inputs:
parameters:
- name: location
description: Location of the imagery to create config for
container:
image: ghcr.io/linz/basemaps/cli:{{=sprig.trim(workflow.parameters['version-basemaps-cli'])}}
command: [node, index.cjs]
image: ghcr.io/linz/basemaps/cli:{{=sprig.trim(workflow.parameters.version_basemaps_cli)}}
command: [node, /app/node_modules/.bin/cogify]
env:
- name: AWS_ROLE_CONFIG_PATH
value: s3://linz-bucket-config/config.json
value: s3://linz-bucket-config/config.basemaps.json
args:
[
"-V",
"create-config",
"--path",
"{{=sprig.trim(inputs.parameters.location)}}",
"--output",
"/tmp/url",
"--commit",
]
- "config"
- "{{ inputs.parameters.location }}"
outputs:
parameters:
- name: url
description: Basemaps URL to view the imagery
valueFrom:
path: "/tmp/url"
path: "/tmp/cogify/config-url"
- name: config
description: Location of the config file
valueFrom:
path: "/tmp/cogify/config-path"
29 changes: 14 additions & 15 deletions workflows/imagery/standardising.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ spec:
- name: version-argo-tasks
value: "v2"
- name: version-basemaps-cli
value: "v6.39.0-15-g3e982390"
value: "v6"
- name: version-topo-imagery
value: "v3"
- name: source
Expand Down Expand Up @@ -484,32 +484,31 @@ spec:
]

- name: create-config
retryStrategy:
limit: "2"
inputs:
parameters:
- name: location
description: Location of the imagery to create config for
container:
image: "ghcr.io/linz/basemaps/cli:{{=sprig.trim(workflow.parameters['version-basemaps-cli'])}}"
command: [node, index.cjs]
command: [node, /app/node_modules/.bin/cogify]
env:
- name: AWS_ROLE_CONFIG_PATH
value: s3://linz-bucket-config/config.json
value: s3://linz-bucket-config/config.basemaps.json
args:
[
"-V",
"create-config",
"--path",
"{{inputs.parameters.location}}flat/",
"--output",
"/tmp/url",
"--title",
"{{=sprig.trim(workflow.parameters.title)}}",
"--commit",
]
- "config"
- "{{ inputs.parameters.location }}flat/"
outputs:
parameters:
- name: url
description: Basemaps URL to view the imagery
valueFrom:
path: "/tmp/cogify/config-url"
- name: config
description: Location of the config file
valueFrom:
path: "/tmp/url"
path: "/tmp/cogify/config-path"

volumes:
- name: ephemeral
Expand Down

0 comments on commit 9b8942d

Please sign in to comment.