[Notes] [Git][BuildGrid/buildgrid][finn/cas-commands] Updates to demos of BuildGrid.



Title: GitLab

finnball pushed to branch finn/cas-commands at BuildGrid / buildgrid

Commits:

1 changed file:

Changes:

  • README.rst
    ... ... @@ -38,7 +38,7 @@ In one terminal, start a server::
    38 38
     
    
    39 39
     In another terminal, send a request for work::
    
    40 40
     
    
    41
    -  bgd execute request
    
    41
    +  bgd execute request-dummy
    
    42 42
     
    
    43 43
     The stage should show as `QUEUED` as it awaits a bot to pick up the work::
    
    44 44
     
    
    ... ... @@ -51,3 +51,35 @@ Create a bot session::
    51 51
     Show the work as completed::
    
    52 52
     
    
    53 53
       bgd execute list
    
    54
    +
    
    55
    +Instructions for a Simple Build
    
    56
    +-------------------------------
    
    57
    +
    
    58
    +This example covers a simple build. The user will upload a directory containing a C file and a command to the CAS. The bot will then fetch the uploaded directory and command which will then be run inside a temporary directory. The result will then be uploaded to the CAS and downloaded by the user. This is an early demo and still lacks a few features such as symlink support and checking to see if files exist in the CAS before executing a command.
    
    59
    +
    
    60
    +Create a new directory called `test-buildgrid/` and place the following C file in it called `hello.c`::
    
    61
    +
    
    62
    +  #include <stdio.h>
    
    63
    +  int main()
    
    64
    +  {
    
    65
    +   printf("Hello, World!\n");
    
    66
    +   return 0;
    
    67
    +  }
    
    68
    +
    
    69
    +Now start a BuildGrid server, passing it a directory it can write a CAS to::
    
    70
    +
    
    71
    +  bgd server start --cas disk --cas-cache disk --cas-disk-directory /path/to/empty/directory
    
    72
    +
    
    73
    +Start the following bot session::
    
    74
    +
    
    75
    +  bgd bot temp-directory
    
    76
    +
    
    77
    +Upload the directory containing the C file::
    
    78
    +
    
    79
    +  bgd cas upload-dir /path/to/test-buildgrid
    
    80
    +
    
    81
    +Now we send an execution request to the bot with the name of the epxected `output-file`, a boolean describing if it is executeable, the path to the directory we uploaded in order to calculate the digest and finally the command to run on the bot::
    
    82
    +
    
    83
    +  bgd execute command --output-file hello True /path/to/test-buildgrid -- gcc -Wall hello.c -o hello
    
    84
    +
    
    85
    +The resulting executeable should have returned to a new directory called `testing/`



  • [Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]