Michael Gaebel
10/27/2023, 4:46 PMaccess_key_id
and secret_access_key
in the hook? All the examples I've seen so far are explicitly configuring credentials. eg docs.
name: Glue Exporter
on:
post-commit:
branches: ["main"]
hooks:
- id: animals_table_glue_exporter
type: lua
properties:
script_path: "scripts/animals_exporter.lua"
args:
aws:
aws_access_key_id: "<AWS_ACCESS_KEY_ID>"
aws_secret_access_key: "<AWS_SECRET_ACCESS_KEY>"
aws_region: "<AWS_REGION>"
and using them to create clients in the lua script:
-- export symlinks
local s3 = aws.s3_client(access_key, secret_key, region)
local result = symlink_exporter.export_s3(s3, table_path, action, {debug=true})
-- register glue table
local glue = aws.glue_client(access_key, secret_key, region)
local res = glue_exporter.export_glue(glue, db, table_path, table_input, action, {debug=true})
So far with LakeFS I've been able to avoid setting up these creds explicitly.Itai Admi
10/27/2023, 6:18 PM{{ ENV.NAME_OF_VAR }}
described here.