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

access denied when share starts server #6

Open
bdw429s opened this issue Nov 17, 2016 · 1 comment
Open

access denied when share starts server #6

bdw429s opened this issue Nov 17, 2016 · 1 comment

Comments

@bdw429s
Copy link
Collaborator

bdw429s commented Nov 17, 2016

I don't have time right now to look at this, but putting this here since it's happened a bunch of times.

Basically, every time I run share and it tries to start the server for me, I get an access denied on the server.json file. I wouldn't expect the file to be locked, but it seems to happen every time on Windows.

CommandBox:commandbox> share

The server needs to be started first.  Doing that now.

ERROR (@build.version@+@build.number@)

D:\commandbox (Access is denied)

C:\Users\Brad.development\.CommandBox\cfml\system\services\ServerService.cfc: line 1211
1209:         // Try to prevent bunping the date modified for no reason
1210:         if( oldJSON != newJSON ) {
1211:             fileWrite( arguments.configFilePath, newJSON );
1212:         }
1213:     }
called from C:\Users\Brad.development\.CommandBox\cfml\system\services\ServerService.cfc: line 356
354:
355:         if( !serverJSON.isEmpty() && serverProps.saveSettings ) {
356:             saveServerJSON( defaultServerConfigFile, serverJSON );
357:         }
358:
called from C:\Users\Brad.development\.CommandBox\cfml\system\modules_app\server-commands\commands\server\start.cfc: line 131
129:
130:             // startup the server
131:             return serverService.start( serverProps = arguments );
132:
133:         // endpointException exception type is used when the endpoint has an issue that needs displayed,
called from C:\Users\Brad.development\.CommandBox\cfml\system\services\CommandService.cfc: line 292
290:             // Run the command
291:             try {
292:                 var result = commandInfo.commandReference.CFC.run( argumentCollection = parameterInfo.namedParameters );
293:                 lastCommandErrored = commandInfo.commandReference.CFC.hasError();
294:             } catch( any e ){
called from C:\Users\Brad.development\.CommandBox\cfml\system\services\CommandService.cfc: line 149
147:         }
148:
149:         return runCommand( commandChain, tokens.toList( ' ' ) );
150:
151:     }
called from C:\Users\Brad.development\.CommandBox\cfml\system\Shell.cfc: line 473
471:                     var result = variables.commandService.runCommandTokens( arguments.command, piped );
472:                 } else {
473:                     var result = variables.commandService.runCommandTokens( arguments.command );
474:                 }
475:             } else {
called from C:\Users\Brad.development\.CommandBox\cfml\system\util\CommandDSL.cfc: line 174
172:             return shell.callCommand( getTokens(), arguments.returnOutput, arguments.piped );
173:         } else {
174:             return shell.callCommand( getTokens(), arguments.returnOutput );
175:         }
176:     }
called from C:\Users\Brad.development\.CommandBox\cfml\modules\box-ngrok\commands\server\share\start.cfc: line 41
39:             serverArgs.openBrowser = false;
40:             command( "server start" )
41:                 .params( argumentCollection = serverArgs )
42:                 .run();
43:             sleep( 1000 );
called from C:\Users\Brad.development\.CommandBox\cfml\system\services\CommandService.cfc: line 292
290:             // Run the command
291:             try {
292:                 var result = commandInfo.commandReference.CFC.run( argumentCollection = parameterInfo.namedParameters );
293:                 lastCommandErrored = commandInfo.commandReference.CFC.hasError();
294:             } catch( any e ){
called from C:\Users\Brad.development\.CommandBox\cfml\system\services\CommandService.cfc: line 131
129:         var commandChain = resolveCommand( line );
130:
131:         return runCommand( commandChain, line );
132:     }
133:
called from C:\Users\Brad.development\.CommandBox\cfml\system\Shell.cfc: line 476
474:                 }
475:             } else {
476:                 var result = variables.commandService.runCommandLine( arguments.command );
477:             }
478:
called from C:\Users\Brad.development\.CommandBox\cfml\system\Shell.cfc: line 425
423:                 // If there's input, try to run it.
424:                 if( len( trim( line ) ) ) {
425:                     callCommand( command=line, initialCommand=true );
426:                 }
427:
called from C:\Users\Brad.development\.CommandBox\cfml\system\Bootstrap.cfm: line 112
110:
111:         // Running the "reload" command will enter this while loop once
112:         while( shell.run( silent=silent ) ){
113:             clearScreen = shell.getDoClearScreen();
114:
@homestar9
Copy link

@bdw429s did you ever find a resolution for this? I'm running into the same issue where share returns an access denied error message:

ERROR (5.5.2+00578)

D:\Dropbox\Repositories\mysite (Access is denied)
  caused by: java.io.FileNotFoundException
  D:\Dropbox\Repositories\mysite (Access is denied)

C:\Users\Henweigh\.CommandBox\cfml\system\services\JSONService.cfc: line 435
433:                    fileSystemUtil.lockingFileWrite( path, newJSON );
434:            } else {
435:                    fileWrite( path, newJSON );
436:            }
437:    }
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\ServerService.cfc: line 2793
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\ServerService.cfc: line 551
called from C:\Users\Henweigh\.CommandBox\cfml\system\modules_app\server-commands\commands\server\start.cfc: line 171
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\CommandService.cfc: line 443
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\CommandService.cfc: line 245
called from C:\Users\Henweigh\.CommandBox\cfml\system\Shell.cfc: line 816
called from C:\Users\Henweigh\.CommandBox\cfml\system\util\CommandDSL.cfc: line 267
called from C:\Users\Henweigh\.CommandBox\cfml\modules\box-ngrok\commands\server\share\start.cfc: line 41
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\CommandService.cfc: line 443
called from C:\Users\Henweigh\.CommandBox\cfml\system\services\CommandService.cfc: line 225
called from C:\Users\Henweigh\.CommandBox\cfml\system\Shell.cfc: line 819
called from C:\Users\Henweigh\.CommandBox\cfml\system\Shell.cfc: line 634
called from C:\Users\Henweigh\.CommandBox\cfml\system\Bootstrap.cfm: line 160

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants