diff --git a/.codesandbox/project.json b/.codesandbox/tasks.json similarity index 74% rename from .codesandbox/project.json rename to .codesandbox/tasks.json index d6a64032b93..a7345e47e39 100644 --- a/.codesandbox/project.json +++ b/.codesandbox/tasks.json @@ -1,10 +1,4 @@ { - "previews": { - "3000": { - "name": "Application", - "command": "yarn start:fast" - } - }, "tasks": { "setup": { "name": "Install Dependencies", @@ -16,11 +10,13 @@ }, "app:fast": { "name": "Application (fast)", - "command": "yarn start:fast" + "command": "yarn start:fast", + "runAtStart": true }, "app:home:fast": { "name": "Application home (fast)", - "command": "yarn start:home:fast" + "command": "yarn start:home:fast", + "runAtStart": true } }, "setupTasks": [ diff --git a/packages/app/src/app/pages/Dashboard/Content/routes/Settings/TeamSettings/RegistryForm.tsx b/packages/app/src/app/pages/Dashboard/Content/routes/Settings/TeamSettings/RegistryForm.tsx index c47031a1ff9..a64ed472942 100644 --- a/packages/app/src/app/pages/Dashboard/Content/routes/Settings/TeamSettings/RegistryForm.tsx +++ b/packages/app/src/app/pages/Dashboard/Content/routes/Settings/TeamSettings/RegistryForm.tsx @@ -10,6 +10,7 @@ import { Icon, Link, Tooltip, + Switch, } from '@codesandbox/components'; import { AuthType, @@ -94,6 +95,9 @@ export const RegistryForm = ({ const [scopes, setScopes] = React.useState( registry?.enabledScopes || [] ); + const [proxyEnabled, setProxyEnabled] = React.useState( + registry?.proxyEnabled + ); const addScope = () => { setScopes(oldScopes => [...oldScopes, '']); @@ -118,7 +122,7 @@ export const RegistryForm = ({ enabledScopes: scopes.filter(s => s !== ''), registryAuthType: authenticationType, registryUrl, - proxyEnabled: true, + proxyEnabled, }); // We make sure to always show one input field @@ -200,6 +204,26 @@ export const RegistryForm = ({ setAuthKey={setAuthKey} disabled={disabled} /> + +
+ + { + setProxyEnabled(s => !s); + }} + on={proxyEnabled} + disabled={disabled} + /> + + + Disabling the proxy will allow you to use the registry behind + a VPN, but will expose the auth token to the browser and + require a CORS setup. + +