This commit is contained in:
Chuck Lantz 2020-10-13 15:43:45 +00:00 коммит произвёл GitHub
Родитель 85a9a2e349
Коммит f415b231f7
4 изменённых файлов: 16 добавлений и 4 удалений

Просмотреть файл

@ -33,7 +33,7 @@
"forwardPorts": [8080, 3306]
// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "sudo rm -rf /var/www/html && sudo ln -s . /var/www/html",
// "postCreateCommand": "sudo chmod a+x \"$(pwd)\" && sudo rm -rf /var/www/html && sudo ln -s \"$(pwd)\" /var/www/html"
// Uncomment to connect as a non-root user. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"

Просмотреть файл

@ -70,8 +70,14 @@ Apache will be available on port `8080`.
If you want to wire in something directly from your source code into the `www` folder, you can add a symlink as follows to `postCreateCommand`:
```json
"postCreateCommand": "sudo chmod a+x \"$(pwd)\" && sudo rm -rf /var/www/html && sudo ln -s \"$(pwd)\" /var/www/html"
```
...or execute this from a terminal window once the container is up:
```bash
sudo rm -rf /var/www/html && sudo ln -s . /var/www/html
sudo chmod a+x "$(pwd)" && sudo rm -rf /var/www/html && sudo ln -s "$(pwd)" /var/www/html
```
### Adding the definition to your project

Просмотреть файл

@ -26,7 +26,7 @@
"forwardPorts": [8080]
// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "sudo rm -rf /var/www/html && sudo ln -s . /var/www/html",
// "postCreateCommand": "sudo chmod a+x \"$(pwd)\" && sudo rm -rf /var/www/html && sudo ln -s \"$(pwd)\" /var/www/html"
// Uncomment to connect as a non-root user. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode"

Просмотреть файл

@ -62,8 +62,14 @@ Apache will be available on port `8080`.
If you want to wire in something directly from your source code into the `www` folder, you can add a symlink as follows to `postCreateCommand`:
```json
"postCreateCommand": "sudo chmod a+x \"$(pwd)\" && sudo rm -rf /var/www/html && sudo ln -s \"$(pwd)\" /var/www/html"
```
...or execute this from a terminal window once the container is up:
```bash
sudo rm -rf /var/www/html && sudo ln -s . /var/www/html
sudo chmod a+x "$(pwd)" && sudo rm -rf /var/www/html && sudo ln -s "$(pwd)" /var/www/html
```
### Adding the definition to your project