Téléverser les fichiers vers "/"

This commit is contained in:
Jean GUIGNARD 2024-12-30 02:05:04 +01:00
commit 1361684b0d
2 changed files with 27 additions and 0 deletions

22
conversion.c Normal file
View file

@ -0,0 +1,22 @@
#include <stdio.h>
#include <stdlib.h>
int main() {
char input[256];
char output[256];
printf("Input file:\n");
scanf("%s", input);
printf("Output file:\n");
scanf("%s", output);
char commande[256];
snprintf(commande, sizeof(commande), "ffmpeg -i %s %s", input, output);
int result = system(commande);
if (result != 0) {
printf("Erreur de conversion\n");
}
return result;
}

5
dockerfile Normal file
View file

@ -0,0 +1,5 @@
FROM gcc:latest
WORKDIR /conversion
COPY conversion.c .
RUN gcc -o conversion conversion.c
CMD [ "./conversion" ]