forked from Ivasoft/github-actions
Debug getting mount points
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -145,6 +145,8 @@ func getWorkDirPath(p Plugin, ctx context.Context) (string, string, error) {
|
||||
return "", "", errors.Wrap(err, "failed to get our container id")
|
||||
}
|
||||
|
||||
fmt.Fprintf(os.Stdout, "Container ID = %s\n", cntrId);
|
||||
|
||||
// Find the proper mount
|
||||
cwd, err := os.Getwd()
|
||||
if err != nil {
|
||||
@@ -157,8 +159,10 @@ func getWorkDirPath(p Plugin, ctx context.Context) (string, string, error) {
|
||||
if err != nil {
|
||||
return "", "", errors.Wrap(err, "failed to inspect ourselves as a container")
|
||||
}
|
||||
fmt.Fprintf(os.Stdout, "Container = %+v\n", cntr);
|
||||
fmt.Fprintf(os.Stdout, "Mounts = %+v\n", cntr.Mounts);
|
||||
for _, i := range cntr.Mounts {
|
||||
fmt.Fprintf(os.Stdout, "Source = %s Destination = %s\n", i.Source, i.Destination);
|
||||
fmt.Fprintf(os.Stdout, "\tDestination = %s\n", i.Destination);
|
||||
if i.Destination == cwd {
|
||||
return i.Source, i.Destination, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user