Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cognac #53

Merged
merged 11 commits into from
Dec 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/regen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ jobs:
sudo apt-get update --fix-missing
sudo apt-get install -y -f -o Acquire::Retries=3 jq libjson-c-dev
- name: regen-test
shell: bash
run: COGNAC_CONFIG="--yq-go" make regen-test
15 changes: 12 additions & 3 deletions examples/example0.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,28 @@ int main(void)
struct osc_str r;
struct osc_read_images_arg arg = {0};
int ret = 1;
int curl_res;

arg.filters_str = "{\"AccountAliases\": [\"Outscale\"]}";
if (osc_init_sdk(&e, NULL, 0) < 0)
if (osc_init_sdk(&e, NULL, 0) < 0) {
fprintf(stderr, "fail to init osc-sdk-c\n");
return 1;
}
osc_init_str(&r);

if (osc_read_load_balancers(&e, &r, NULL))
curl_res = osc_read_load_balancers(&e, &r, NULL);
if (curl_res) {
fprintf(stderr, "fail to read load balancer %s\n",
curl_easy_strerror(curl_res));
goto out;
}
printf("== osc_read_load_balancers ==\n%s\n", r.buf);
osc_deinit_str(&r);

if (osc_read_images(&e, &r, &arg) < 0)
if (osc_read_images(&e, &r, &arg) < 0) {
fprintf(stderr, "fail to read images\n");
goto out;
}
printf("== osc_read_images ==\n%s\n", r.buf);

ret = 1;
Expand Down
3 changes: 2 additions & 1 deletion intergration-test.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#!/bin/bash


is_local=0
echo $OSC_ENDPOINT_API | grep 127.0.0.1 > /dev/null
if [ $? -eq 0 ]; then
./ricochet_preparation
is_local=1
fi

set -eE
Expand Down
Loading
Loading