Skip to content

Commit 6623eaf

Browse files
authored
Merge pull request #1430 from MicrosoftDocs/master
2/12 AM Publish
2 parents 238cd48 + 752251a commit 6623eaf

File tree

3 files changed

+27
-10
lines changed

3 files changed

+27
-10
lines changed

connected-environment/common/build-and-run-in-k8s-cli.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,4 +20,4 @@ Scan the console output for information about the public URL that was created by
2020

2121
`Running at public URL: https://<servicename>-<environmentname>.vsce.io`
2222

23-
Open this URL in a browser window - or better yet, from a mobile device - and you should see the web app load. As the container executes, `stdout` and `stderr` output is streamed to the terminal window.
23+
Open this URL in a browser window, and you should see the web app load. As the container executes, `stdout` and `stderr` output is streamed to the terminal window.

connected-environment/get-started-nodejs-03.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,25 @@ Connected Environment isn't just about getting code running in Kubernetes - it's
2525

2626
What happened? Edits to content files, like HTML and CSS, don't require the Node.js process to restart, so an active `vsce up` command will automatically sync any modified content files directly into the running container in Azure, thereby providing a fast way to see your content edits.
2727

28+
### Test from a mobile device
29+
If you open the web app on a mobile device, you will notice that the UI does not display properly on a small device.
30+
31+
To fix this, we'll add a `viewport` meta tag:
32+
1. Open the file `./public/index.html`
33+
1. Add a `viewport` meta tag in the existing `header` tag:
34+
35+
```html
36+
<header>
37+
<!-- Add this line -->
38+
<meta name="viewport" content="width=device-width, initial-scale=1">
39+
</header>
40+
```
41+
42+
1. Save the file.
43+
1. Refresh your device's browser. You should now see the web app rendered correctly.
44+
45+
This is an example of how some problems just aren't found until you test on the devices an app is meant to be used. With VS Connected Environment you can rapidly iterate on your code and validate any changes on target devices.
46+
2847
## Update a code file
2948
Updating server-side code files requires a little more work, because a Node.js app needs to restart.
3049

connected-environment/troubleshooting.md

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,14 @@ Install the [VS Code extension for Connected Environment](get-started-netcore-01
4646
**Reason:** An Azure portal experience for Connected Environment is not yet ready for preview.
4747

4848

49-
## Error during warmup displayed in Visual Studio Output Window
50-
An error occurred during warmup for project '<projectname>'
49+
## The type or namespace name 'MyLibrary' could not be found
5150

52-
**Reason:** This occurs when Visual Studio attempts to warmup a Connected Environment that has not yet finished being created, or is in an incomplete or error state. You will often see this right after you have started to create a new Connected Environment.
51+
**Reason:** The build context is at the project/service level by default, therefore a library project you are using will not be found.
5352

5453
**Try:**
55-
If you have just started the creation of a new Connected Environment, wait until it is successfully created before attempting to F5 or Ctrl+F5 your project/service. If this is a Connected Environment you created more than 15 minutes ago, it is likely in a bad state. You can try creating a new environment and wait for it to successfully be created.
54+
What needs to be done is:
55+
1. Modify the vsce.yaml file to set the build context to the solution level.
56+
2. Modify the Dockerfile and Dockerfile.develop files to refer to the csproj files correctly, relative to the new build context.
57+
3. Place a .dockerignore file beside the .sln file and modify as needed.
5658

57-
You can see if your Connected Environment is still being created by *hovering your cursor* over the **Background tasks** icon in the bottom left corner of the status bar.
58-
![](images/BackgroundTasks.png)
59-
60-
You can also see if a Connected Environment you recently created from within Visual Studio has been created sucessfully by *clicking* on the **Background tasks** icon in the bottom left corner of the status bar.
61-
![](images/BackgroundTasks2.png)
59+
You can find an example at https://github.com/sgreenmsft/buildcontextsample

0 commit comments

Comments
 (0)