- Theme : Atom One Dark
- Icon Theme : Material Icon Theme
- Font : Monospace
- Extensions Installed :
- Bracket Pair Colorizer 2
- C# Intellisense
- C/C++ Intellisense
- Code Runner
- Draw.io Integration
- Language Support for Java(TM) by Red Hat
- Markdown All in One
- NPM Intellisense
- PowerShell
- Python Intellisense
- VSCode Action Buttons
- rust-lang
- Google Drive Upload
- Languages Installed :
CS_VERSION | 3.11 |
---|---|
AUTH_TYPE | Code-Server login type: {password, none} |
PASSWORD | Code-Server login password (If AUTH_TYPE=password) |
CODESERVER_PORT | Code-Server web access port |
CUSTOM_HOME | Custom home directory for Heroku |
WORKSPACE_DIR | Code-Server working directory |
NGROK_TOKEN | Ngrok Token |
- For Heroku Users :
- Fork this repo.
- Create new app on heroku.
- Setting up google drive (do the following on local pc) :
- [ ! ] If you don't want this feature then don't assign any value to
DRIVE_ACCESS
variable. - Follow this & get your
client_secret.json
file. - Add Drive API to the project from here, select the same project made in the above step if needed.
- Clone/Download this repo.
- Install Python-3 & install all the requirements via [CLONED/DOWNLOADED REPO]/requirements.txt
- Now paste your
client_secret.json
file into the [CLONED/DOWNLOADED REPO] folder. - Open a terminal in the repo folder and run the upload.py:
python3 upload.py -i upload.py -f "CodeServer Saves" --noauth_local_webserver
- Copy the URL from the terminal & paste it into browser.
- Login with your account, accept all the terms, get the success key.
- Paste it into the terminal & wait for the success message.
- Now check your drive for
CodeServer Saves
folder and aupload.py
file inside it. - If its not there, run
python3 upload.py -i upload.py -f "CodeServer Saves"
, now check in drive. - Now go here and upload your
drive-access.json
from[CLONED/DOWNLOADED REPO]/.credentials/drive-access.json
. - Now copy the download link & paste it into the
DRIVE_ACCESS_URL
inDockerfile.heroku
of your forked repo and save it. - [ ! ] Download link is a single download link, so repeat from the file upload process if you re-deploy the project.
- [ ! ] If you don't want this feature then don't assign any value to
- Now hit the Heroku Deploy button on the forked repo's readme.
- [ ! ] Set
AUTH_TYPE
value tonone
if you dont want any login password prompt.
- For Non-Heroku Users :
- Setting up google drive (do the following on local pc) :
- [ ! ] If you don't want this feature then don't assign any value to
DRIVE_ACCESS
variable in the run command. - Follow this & get your
client_secret.json
file. - Add Drive API to the project from here, select the same project made in the above step if needed.
- Clone/Download this repo.
- Install Python-3 & install all the requirements for the cloned repo via requirements.txt
- Now paste your
client_secret.json
file into the repo folder. - Open a terminal in the repo folder and run the upload.py:
python3 upload.py -i upload.py -f "CodeServer Saves" --noauth_local_webserver
- Copy the URL from the terminal & paste it into browser.
- Login with your account, accept all the terms, get the success key.
- Paste it into the terminal & wait for the success message.
- Now check your drive for
CodeServer Saves
folder and aupload.py
file inside it. - If it's not there, run
python3 upload.py -i upload.py -f "CodeServer Saves"
, now check in drive. - Now copy the
drive_access.json
from[CLONED/DOWNLOADED REPO]/.credentials/drive-access.json
to your system where you want to run code-server. Edit & Run Command :[ ! ] Setdocker run --name code-server \ -e AUTH_TYPE="password" \ -e PASSWORD="samplepass" \ -e CODESERVER_PORT="9870" \ -e NGROK_TOKEN="<YOUR NGROK TOKEN>" \ -d -p 8080:9870 vital987/code-server && \ docker cp <path to drive_access.json> code-server:/app/.credentials
AUTH_TYPE
value tonone
if you dont want any login password prompt.
- [ ! ] If you don't want this feature then don't assign any value to
- Setting up google drive (do the following on local pc) :
- Open the heroku app URL, non-heroku users, port-forward the using Ngrok:
ngrok http $CODESERVER_PORT
- Login with the password (value of $PASSWORD).
- Buttons present at the bottom bar :
- ↻ : Refresh the buttons.
- ClearWorkspace : Deletes all the folders in workspace directory.
- ResetWorkspace : Resets the workspace folder with all sample files.
- DriveUpload : Archive workspace directory (excluding sample files) and upload to google drive.
- [ ! ] The buttons need to be refreshed everytime after use.