Skip to content

Commit

Permalink
ci: build devcontainer and push
Browse files Browse the repository at this point in the history
  • Loading branch information
mcanouil committed Nov 15, 2023
1 parent b03e34a commit d203a93
Show file tree
Hide file tree
Showing 12 changed files with 55 additions and 42 deletions.
2 changes: 0 additions & 2 deletions .devcontainer/Dockerfile

This file was deleted.

38 changes: 1 addition & 37 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,43 +1,7 @@
{
"name": "eggla",
"build": {
"dockerfile": "Dockerfile",
"args": {
"VARIANT": "bullseye"
}
},
"image": "buildpack-deps:bullseye-curl",
"remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "true",
"username": "vscode",
"userUid": "1001",
"userGid": "1001",
"upgradePackages": "true"
},
"ghcr.io/devcontainers/features/git:1": {
"version": "latest",
"ppa": "false"
},
"ghcr.io/rocker-org/devcontainer-features/r-rig:1": {
"version": "4.2.0",
"vscodeRSupport": "full",
"installDevTools": "false",
"installREnv": "true",
"installRMarkdown": "false"
},
"ghcr.io/rocker-org/devcontainer-features/quarto-cli:1": {
"version": "prerelease",
"installTinyTex": "false",
"installChromium": "false"
},
"./bcftools": {
"version": "1.16"
},
"./eggla": {
"version": "main"
}
},
"customizations": {
"vscode": {
"extensions": [
Expand Down
File renamed without changes.
48 changes: 48 additions & 0 deletions .github/.devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{
"name": "eggla",
"image": "ghcr.io/mcanouil/eggla:devel",
"remoteUser": "vscode",
"remoteEnv": {
"PKG_SYSREQS": "true"
},
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "true",
"username": "vscode",
"userUid": "1001",
"userGid": "1001",
"upgradePackages": "true"
},
"ghcr.io/devcontainers/features/git:1": {
"version": "latest",
"ppa": "false"
},
"ghcr.io/rocker-org/devcontainer-features/r-rig:1": {
"version": "4.2.0",
"vscodeRSupport": "full",
"installDevTools": "false",
"installREnv": "true",
"installRMarkdown": "false"
},
"./bcftools": {
"version": "1.16"
},
"./eggla": {
"version": "main"
}
},
"customizations": {
"vscode": {
"extensions": [
"REditorSupport.r"
],
"settings": {
"r.rterm.option": [
"--no-save",
"--no-restore-data",
"--quiet"
]
}
}
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,8 @@ check_packages curl \
libfribidi-dev \
libv8-dev \
libudunits2-dev \
libfftw3-dev
libfftw3-dev \
libgit2-dev

install_pak() {
local version=$1
Expand All @@ -102,9 +103,11 @@ echo "Install R packages..."
mkdir /tmp/r-packages
pushd /tmp/r-packages


install_pak "auto"

su "${USERNAME}" -c "R -q -e \"pak::lockfile_install(update = TRUE)\""
cp ${FEATURE_DIR}/R/pkg.lock pkg.lock
su "${USERNAME}" -c "R -q -e \"n <- 0; while(inherits(try(pak::lockfile_install(update = TRUE), silent = TRUE), 'try-error') && n < 3) n <- n + 1\""

if [ "${EGGLA_VERSION}" = "main" ]; then
su "${USERNAME}" -c "R -q -e \"pak::pkg_install('mcanouil/eggla', upgrade = FALSE, dependencies = TRUE)\""
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion .github/workflows/devcontainer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ concurrency:
cancel-in-progress: true

jobs:
build-docker:
build-devcontainer:
runs-on: ubuntu-latest
if: |
github.event_name == 'workflow_dispatch' ||
Expand Down

0 comments on commit d203a93

Please sign in to comment.