Conversation
cli/commands/project_sync.go
Outdated
| cmd.out.Verbose.Printf("Setting up local volume: %s", volumeName) | ||
| cmd.SetupBindVolume(volumeName) | ||
| default: | ||
| cmd.out.Verbose.Printf("Volume Sync not supported on: %s", platform) |
There was a problem hiding this comment.
Does unison not work on Windows?
There was a problem hiding this comment.
Don't know, we have not tried it yet, but at a minimum the binary would likely be something like unison.exe so our current command would not be supported. I think windows also does cli options differently.
There was a problem hiding this comment.
Ah, so currently we are in aggressive conflict with Windows. Perhaps in the recent change to generator-outrigger-drupal, I should have it use the "devcloud" options for non-Darwin, instead of for linux specifically.
There was a problem hiding this comment.
I'm confused what hole are we leaving Windows users in? Is it "Add Unison support on Windows" or is it "Treat Windows like Linux"?
There was a problem hiding this comment.
Windows support would be "Treat Windows like Mac"
There was a problem hiding this comment.
Oh, I see what you mean.... let's default to what mac does and lets just use Linux as the single case.
|
Moved from WIP to legit PR. Verified |
cli/commands/project_sync.go
Outdated
| cmd.out.Verbose.Printf("Setting up local volume: %s", volumeName) | ||
| cmd.SetupBindVolume(volumeName) | ||
| default: | ||
| cmd.out.Verbose.Printf("Volume Sync not supported on: %s", platform) |
There was a problem hiding this comment.
I'm confused what hole are we leaving Windows users in? Is it "Add Unison support on Windows" or is it "Treat Windows like Linux"?
| "volume", "create", | ||
| "--opt", "type=none", | ||
| "--opt", fmt.Sprintf("device=%s", workingDir), | ||
| "--opt", "o=bind", |
There was a problem hiding this comment.
To be clear, the lack of specifying ro meant this is a read/write binding?
There was a problem hiding this comment.
Are you suggesting that we explicitly mark it :rw
| // Start the unison sync process | ||
| func (cmd *ProjectSync) RunStop(ctx *cli.Context) error { | ||
| if runtime.GOOS == "linux" { | ||
| cmd.out.Info.Println("No unison container to stop, using local bind volume") |
There was a problem hiding this comment.
Since we are creating the volume as an external, shouldn't this stop the volume for them?
And if so, as long as any action is taken I think logging about no-op should be verbose.
There was a problem hiding this comment.
Volumes are not start or stopped, they just exist. Are you suggesting we do the volume remove here in the stop?
There was a problem hiding this comment.
Nope, you are right, we should probably not do a volume remove here.
Some exploration into having linux use bind volume mounts (instead of unison) so that we don't need different configs for volumes on mac & linux