Compare commits

...

4 Commits

4 changed files with 11 additions and 5 deletions

View File

@ -14,5 +14,5 @@ replace_home() {
find .config -type d -exec chmod g+x {} + find .config -type d -exec chmod g+x {} +
replace_home "$PWD" "/home/devuser" replace_home "$PWD" "/home/devuser"
tar -czf home.tar.gz --owner root:0 --group secproc:1002 --xform "s,$PWD,/home/devuser," .config .local .ssh start.sh tar --mode=a=r,u+w,a+x -czf home.tar.gz --owner root:0 --group root:0 --xform "s,$PWD,/home/devuser," .config .local .ssh
replace_home "/home/devuser" "$PWD" replace_home "/home/devuser" "$PWD"

View File

@ -1,7 +1,6 @@
Host alps Host alps
HostName 10.88.0.1 HostName 10.88.0.1
User git User git
IdentityFile ~/.ssh/id_ed25519
IdentitiesOnly yes IdentitiesOnly yes
StrictHostKeyChecking yes StrictHostKeyChecking yes
Port 2222 Port 2222
@ -10,7 +9,6 @@ Host alps
Host github Host github
HostName github.com HostName github.com
User git User git
IdentityFile ~/.ssh/id_ed25519
IdentitiesOnly yes IdentitiesOnly yes
StrictHostKeyChecking yes StrictHostKeyChecking yes
ProxyCommand none ProxyCommand none

8
.vscode/tasks.json vendored
View File

@ -56,6 +56,14 @@
"problemMatcher": [], "problemMatcher": [],
"detail": "Copy gitconfig.template to $HOME/" "detail": "Copy gitconfig.template to $HOME/"
}, },
{
"label": "GitOps(Update): start.sh",
"type": "shell",
"command": ".bin/gitops update start.sh",
"group": "build",
"problemMatcher": [],
"detail": "Copy start.sh to $HOME/"
},
{ {
"label": "Create home tarball", "label": "Create home tarball",
"type": "shell", "type": "shell",

View File

@ -19,8 +19,7 @@ RUN pacman -Sy --noconfirm && \
# Create user/groups as per your script, with -l to avoid system user quirks # Create user/groups as per your script, with -l to avoid system user quirks
RUN groupadd -g $DEV_GID $DEV_USER && \ RUN groupadd -g $DEV_GID $DEV_USER && \
groupadd -g 2000 secproc && \ useradd -l -ms /bin/fish -u $DEV_UID -g $DEV_GID $DEV_USER
useradd -l -ms /bin/fish -G secproc -u $DEV_UID -g $DEV_GID $DEV_USER
# ──────────────────────── # ────────────────────────
# Stage 2: Workspace Image # Stage 2: Workspace Image
@ -36,6 +35,7 @@ ARG POD_UID=1002
# Use ADD for extracting archives # Use ADD for extracting archives
ADD home.tar.gz $DEV_HOME ADD home.tar.gz $DEV_HOME
COPY --chmod=755 start.sh $DEV_HOME/
# Prepare .ssh and known_hosts, and fix permissions only if dirs exist # Prepare .ssh and known_hosts, and fix permissions only if dirs exist
RUN mkdir -p $DEV_HOME/.ssh && \ RUN mkdir -p $DEV_HOME/.ssh && \