Skip to content

Commit 6465869

Browse files
committed
update for dev workspace
1 parent 0cb66f9 commit 6465869

File tree

2 files changed

+19
-2
lines changed

2 files changed

+19
-2
lines changed

ansible/vars/dev.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
dotfiles_src_dir: ~/src
2+
dotfiles_git_repos:
3+
- src: [email protected]:coder/coder
4+
dest: ~/src/coder
5+
version: main
6+
dotfiles_packages: [] # all present in image

install.sh

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,27 @@
11
#!/usr/bin/env bash
2-
#!/usr/bin/env bash
32

43
set -euo pipefail
54

65
[[ -z "${VERBOSE:-}" ]] || set -x
76

87
REPO_ROOT=$(git rev-parse --show-toplevel)
98

9+
# Ensure python3 is available
10+
if ! command -v python3; then
11+
echo "INFO: installing python3"
12+
DEBIAN_FRONTEND=noninteractive sudo apt-get install --no-install-recommends -y python3 python3-virtualenv python3-apt
13+
fi
14+
15+
# Ensure virtualenv is available
16+
if ! command -v virtualenv; then
17+
echo "INFO: installing virtualenv"
18+
DEBIAN_FRONTEND=noninteractive sudo apt-get install --no-install-recommends -y python3-virtualenv
19+
fi
20+
1021
# Create a virtualenv
1122
if [[ ! -d "${REPO_ROOT}/.venv" ]]; then
1223
echo "INFO: Creating virtualenv"
13-
python3 -m venv "${REPO_ROOT}/.venv"
24+
virtualenv "${REPO_ROOT}/.venv"
1425
fi
1526

1627
# Activate the virtualenv

0 commit comments

Comments
 (0)