From 441af98bb78058cf5e84c416b67763081a82e540 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:15:11 -0400 Subject: [PATCH 01/23] goss tests --- connect/.env | 2 ++ connect/docker-compose.test.yml | 2 ++ connect/test/goss.yaml | 47 +++++++++++++++++-------- package-manager/.env | 1 + package-manager/docker-compose.test.yml | 1 + package-manager/test/goss.yaml | 24 +++++++++++-- server-pro/.env | 5 +++ server-pro/docker-compose.test.yml | 4 +++ server-pro/test/goss.yaml | 41 ++++++++++++--------- 9 files changed, 93 insertions(+), 34 deletions(-) diff --git a/connect/.env b/connect/.env index 4b537f067..468cd891d 100644 --- a/connect/.env +++ b/connect/.env @@ -1 +1,3 @@ RSC_VERSION=1.8.8.2 +R_VERSION=3.6.2 +PYTHON_VERSION=3.6.5 \ No newline at end of file diff --git a/connect/docker-compose.test.yml b/connect/docker-compose.test.yml index 40f1cb705..9c8204bfc 100644 --- a/connect/docker-compose.test.yml +++ b/connect/docker-compose.test.yml @@ -9,6 +9,8 @@ services: environment: # uses .env by default - RSC_VERSION + - R_VERSION + - PYTHON_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" diff --git a/connect/test/goss.yaml b/connect/test/goss.yaml index 674871c76..6e141465f 100644 --- a/connect/test/goss.yaml +++ b/connect/test/goss.yaml @@ -15,35 +15,54 @@ package: file: /etc/rstudio-connect/license.lic: - # currently does not exist - # be sure it is NOT a directory + # Currently does not exist + # Be sure it is NOT a directory exists: false /opt/rstudio-connect/: exists: true /opt/rstudio-connect/bin/connect: exists: true + /usr/local/bin/tini: + exists: true +# Ensure startup file exists + /usr/local/bin/startup.sh: + exists: true + owner: root + group: root + filetype: file +# Ensure log files exist + /var/log/rstudio-connect.log: + exists: true + /opt/python/{{.Env.PYTHON_VERSION}}/bin/python: + exists: true -# check product version +# Check product version command: "/opt/rstudio-connect/bin/connect --version": - title: connect_version_matches - exit-status: 0 - stdout: [ + title: connect_version_matches + exit-status: 0 + stdout: [ "/{{ .Env.RSC_VERSION }}/" - ] - # goss times out after 10 seconds + ] + +# Goss times out after 10 seconds "timeout --signal=SIGINT 7 /opt/rstudio-connect/bin/connect --config /etc/rstudio-connect/rstudio-connect.gcfg": title: connect_starts - # the timeout should stop connect, not a failure + # The timeout should stop connect, not a failure exit-status: 124 - # maybe optimistic that Connect finishes starting... - #stderr: [ - # "Starting HTTP listener on :3939" - #] + +# Ensure correct R version "/opt/R/3.6.2/bin/R --version": title: r_version_match exit-status: 0 stdout: [ - "/3.6.2/" + "/{{.Env.R_VERSION}}/" ] +# Ensure correct python version + "/opt/python/3.6.5/bin/python --version": + title: python_version_matches + exit-status: 0 + stderr: [ + "/{{.Env.PYTHON_VERSION}}/" + ] \ No newline at end of file diff --git a/package-manager/.env b/package-manager/.env index bff087a5f..8a174c15d 100644 --- a/package-manager/.env +++ b/package-manager/.env @@ -1 +1,2 @@ RSPM_VERSION=1.2.2.1-17 +R_VERSION=3.6.2 \ No newline at end of file diff --git a/package-manager/docker-compose.test.yml b/package-manager/docker-compose.test.yml index 6b3c5f11b..22970f357 100644 --- a/package-manager/docker-compose.test.yml +++ b/package-manager/docker-compose.test.yml @@ -8,6 +8,7 @@ services: environment: # uses .env by default - RSPM_VERSION + - R_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" diff --git a/package-manager/test/goss.yaml b/package-manager/test/goss.yaml index 7a1719132..5116bd9e5 100644 --- a/package-manager/test/goss.yaml +++ b/package-manager/test/goss.yaml @@ -15,8 +15,8 @@ package: file: /etc/rstudio-pm/license.lic: - # currently does not exist - # be sure it is NOT a directory +# Currently does not exist +# Be sure it is NOT a directory exists: false /opt/rstudio-pm/: exists: true @@ -26,8 +26,14 @@ file: exists: true /usr/local/bin/rspm: exists: true + /usr/local/bin/tini: + exists: true + /var/log/rstudio-pm.log: + exists: true + filetype: file + -# check product version +# Check product version command: "/opt/rstudio-pm/bin/rstudio-pm --version": title: package-manager_version_matches @@ -35,3 +41,15 @@ command: stdout: [ "/{{ .Env.RSPM_VERSION }}/" ] +# Ensure package manager is running + "/opt/rstudio-pm/bin/rstudio-pm --config /etc/rstudio-pm/rstudio-pm.gcfg": + title: rspm_start + exit-status: 0 + +# Ensure correct R version + "/opt/R/3.6.2/bin/R --version": + title: r_version_match + exit-status: 0 + stdout: [ + "/{{ .Env.R_VERSION }}/" + ] \ No newline at end of file diff --git a/server-pro/.env b/server-pro/.env index 954617921..5336ebcf6 100644 --- a/server-pro/.env +++ b/server-pro/.env @@ -1,3 +1,8 @@ RSP_VERSION=1.4.1717-3 RSP_DOWNLOAD_URL=https://download2.rstudio.org/server/bionic/amd64 RSP_NAME=rstudio-workbench +PYTHON_VERSION=3.9.5 +ALT_PYTHON_VERSION=3.8.10 +JUPYTER_PYTHON_VERSION=3.8.10 +R_VERSION=4.1.0 + diff --git a/server-pro/docker-compose.test.yml b/server-pro/docker-compose.test.yml index d7df72404..51c86dae8 100644 --- a/server-pro/docker-compose.test.yml +++ b/server-pro/docker-compose.test.yml @@ -8,6 +8,10 @@ services: environment: # uses .env by default - RSP_VERSION + - R_VERSION + - PYTHON_VERSION + - ALT_PYTHON_VERSION + - JUPYTER_PYTHON_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" diff --git a/server-pro/test/goss.yaml b/server-pro/test/goss.yaml index 92ef3a5b4..b211af53f 100644 --- a/server-pro/test/goss.yaml +++ b/server-pro/test/goss.yaml @@ -20,16 +20,16 @@ file: exists: false /usr/lib/rstudio-server: exists: true - /opt/R/3.6.3/bin/R: + /opt/R/{{.Env.ALT_R_VERSION}}/bin/R: exists: true filetype: file - /opt/R/4.1.0/bin/R: + /opt/R/{{.Env.R_VERSION}}/bin/R: exists: true filetype: file - /opt/python/3.9.5/bin/python: + /opt/python/{{.Env.PYTHON_VERSION}}/bin/python: exists: true filetype: symlink - /opt/python/3.8.10/bin/python: + /opt/python/{{.Env.ALT_PYTHON_VERSION}}/bin/python: exists: true filetype: symlink /opt/python/jupyter/bin/python: @@ -50,6 +50,7 @@ file: owner: rstudio-server group: rstudio-server + command: "su rstudio-server -c 'touch /var/lib/rstudio-server/monitor/log/rstudio-server.log'": title: server-pro_monitor_log_file_creates @@ -57,38 +58,44 @@ command: "touch /var/log/rstudio-server.log": title: server-pro_server_log_creates exit-status: 0 - # check product version - #"rstudio-server version": - # title: server-pro_version_matches - # exit-status: 0 - # stdout: [ - # "/{{ .Env.RSP_VERSION }}/", - # "/Pro/" # this will switch to Workbench when we release the preview build - # ] + +# Check product version + "rstudio-server version": + title: server-pro_version_matches + exit-status: 0 + stdout: [ + "/{{ .Env.RSP_VERSION }}/", + "/Workbench/" + ] + "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/jupyter/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 + +# Ensure correct python version "/opt/python/3.8.10/bin/python --version": - title: python_version_matches + title: alternate_python_version_matches exit-status: 0 stdout: [ - "/3.8.10/" + "/{{.Env.ALT_PYTHON_VERSION}}/" ] +# Ensure correct python version "/opt/python/3.9.5/bin/python --version": title: python_version_matches exit-status: 0 stdout: [ - "/3.9.5/" + "/{{.Env.PYTHON_VERSION}}/" ] "/opt/python/jupyter/bin/python --version": title: jupyter_python_version_matches exit-status: 0 stdout: [ - "/3.8.10/" + "/{{.Env.JUPYTER_PYTHON_VERSION}}/" ] + "which openssl": title: uses_system_openssl exit-status: 0 stdout: [ "/usr/bin/openssl" - ] + ] \ No newline at end of file From 686e86c8f92cca05a08ec9c02d5a2deebdc1338a Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:35:21 -0400 Subject: [PATCH 02/23] alternate r version rsp --- connect/test/goss.yaml | 8 ++++---- server-pro/.env | 3 ++- server-pro/docker-compose.test.yml | 1 + 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/connect/test/goss.yaml b/connect/test/goss.yaml index 6e141465f..2607ac695 100644 --- a/connect/test/goss.yaml +++ b/connect/test/goss.yaml @@ -52,17 +52,17 @@ command: exit-status: 124 # Ensure correct R version - "/opt/R/3.6.2/bin/R --version": + "/opt/R/{{ .Env.R_VERSION }}/bin/R --version": title: r_version_match exit-status: 0 stdout: [ - "/{{.Env.R_VERSION}}/" + "/{{ .Env.R_VERSION }}/" ] # Ensure correct python version - "/opt/python/3.6.5/bin/python --version": + "/opt/python/{{ .Env.PYTHON_VERSION }}/bin/python --version": title: python_version_matches exit-status: 0 stderr: [ - "/{{.Env.PYTHON_VERSION}}/" + "/{{ .Env.PYTHON_VERSION }}/" ] \ No newline at end of file diff --git a/server-pro/.env b/server-pro/.env index 5336ebcf6..6c16034f6 100644 --- a/server-pro/.env +++ b/server-pro/.env @@ -4,5 +4,6 @@ RSP_NAME=rstudio-workbench PYTHON_VERSION=3.9.5 ALT_PYTHON_VERSION=3.8.10 JUPYTER_PYTHON_VERSION=3.8.10 -R_VERSION=4.1.0 +ALT_R_VERSION=4.1.0 +R_VERSION=3.6.2 diff --git a/server-pro/docker-compose.test.yml b/server-pro/docker-compose.test.yml index 51c86dae8..965392460 100644 --- a/server-pro/docker-compose.test.yml +++ b/server-pro/docker-compose.test.yml @@ -12,6 +12,7 @@ services: - PYTHON_VERSION - ALT_PYTHON_VERSION - JUPYTER_PYTHON_VERSION + - ALT_R_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" From 3066d3da9a23aa6a242dee7be090dbba889b0a69 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:53:34 -0400 Subject: [PATCH 03/23] secrets test --- .github/goss-image-tests.yaml | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .github/goss-image-tests.yaml diff --git a/.github/goss-image-tests.yaml b/.github/goss-image-tests.yaml new file mode 100644 index 000000000..e36244cb2 --- /dev/null +++ b/.github/goss-image-tests.yaml @@ -0,0 +1,10 @@ +name: Goss Image Testing +on: push +jobs: + job1: + runs-on: ubuntu-latest + steps: + env: + RSC_LICENSE: ${{ secrets.RSC_LICENSE }} + RSP_LICENSE: ${{ secrets.RSP_LICENSE }} + RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} From 6f6ee5bcb1bcfa5db265158dc7ee06a85067d594 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:54:20 -0400 Subject: [PATCH 04/23] add to workflow --- .github/{ => workflows}/goss-image-tests.yaml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/{ => workflows}/goss-image-tests.yaml (100%) diff --git a/.github/goss-image-tests.yaml b/.github/workflows/goss-image-tests.yaml similarity index 100% rename from .github/goss-image-tests.yaml rename to .github/workflows/goss-image-tests.yaml From 0a9957d9b3afb0e80c388918df2e8fc3bee210fa Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:56:16 -0400 Subject: [PATCH 05/23] update goss workflow --- .github/workflows/goss-image-tests.yaml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/goss-image-tests.yaml b/.github/workflows/goss-image-tests.yaml index e36244cb2..071a25b1c 100644 --- a/.github/workflows/goss-image-tests.yaml +++ b/.github/workflows/goss-image-tests.yaml @@ -2,9 +2,8 @@ name: Goss Image Testing on: push jobs: job1: - runs-on: ubuntu-latest - steps: - env: - RSC_LICENSE: ${{ secrets.RSC_LICENSE }} - RSP_LICENSE: ${{ secrets.RSP_LICENSE }} - RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} + runs-on: ubuntu-latest + env: + RSC_LICENSE: ${{ secrets.RSC_LICENSE }} + RSP_LICENSE: ${{ secrets.RSP_LICENSE }} + RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} From c9804ad05a84dd7fc0bae5fc4828a9232fb706ec Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 17:59:02 -0400 Subject: [PATCH 06/23] update workflow --- .github/workflows/goss-image-tests.yaml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/.github/workflows/goss-image-tests.yaml b/.github/workflows/goss-image-tests.yaml index 071a25b1c..a8e0d2c2f 100644 --- a/.github/workflows/goss-image-tests.yaml +++ b/.github/workflows/goss-image-tests.yaml @@ -1,9 +1,13 @@ -name: Goss Image Testing +name: goss-secrets-test on: push jobs: job1: - runs-on: ubuntu-latest - env: - RSC_LICENSE: ${{ secrets.RSC_LICENSE }} - RSP_LICENSE: ${{ secrets.RSP_LICENSE }} - RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} + runs-on: ubuntu-latest + steps: + - name: Test + run: | + echo secrets-configured + env: + RSC_LICENSE: ${{ secrets.RSC_LICENSE }} + RSP_LICENSE: ${{ secrets.RSP_LICENSE }} + RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} From 352c5f6d2cf1d168bccbc1eae044402b81a33f2d Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 18:52:28 -0400 Subject: [PATCH 07/23] r-session-complete updates --- r-session-complete/bionic/.env | 4 +++ .../bionic/docker-compose.test.yml | 5 +++- r-session-complete/bionic/test/goss.yaml | 28 +++++++++++++++++++ r-session-complete/bionic/test/goss_vars.yaml | 7 +++++ .../centos7/docker-compose.test.yml | 1 + 5 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 r-session-complete/bionic/.env create mode 100644 r-session-complete/bionic/test/goss_vars.yaml diff --git a/r-session-complete/bionic/.env b/r-session-complete/bionic/.env new file mode 100644 index 000000000..9b8735947 --- /dev/null +++ b/r-session-complete/bionic/.env @@ -0,0 +1,4 @@ +R_VERSION=4.0.2 +PYTHON_VERSION=3.7.7 +DRIVERS_VERSION=1.7.0 +RSP_VERSION=1.4.1717-3 \ No newline at end of file diff --git a/r-session-complete/bionic/docker-compose.test.yml b/r-session-complete/bionic/docker-compose.test.yml index d7df72404..dded891b4 100644 --- a/r-session-complete/bionic/docker-compose.test.yml +++ b/r-session-complete/bionic/docker-compose.test.yml @@ -2,12 +2,15 @@ version: '2.3' services: sut: - image: $IMAGE_NAME + image: "6e2d311047c4" command: /run_tests.sh entrypoint: [] environment: # uses .env by default - RSP_VERSION + - R_VERSION + - PYTHON_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" + - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" \ No newline at end of file diff --git a/r-session-complete/bionic/test/goss.yaml b/r-session-complete/bionic/test/goss.yaml index 3481757f8..d5875ad82 100644 --- a/r-session-complete/bionic/test/goss.yaml +++ b/r-session-complete/bionic/test/goss.yaml @@ -3,8 +3,36 @@ file: exists: true /usr/lib/rstudio-server/bin/rsession: exists: true + /opt/code-server/: + exists: true + filetype: directory + /opt/rstudio-drivers: + exists: true + filetype: directory command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 + {{ $pkgs := .Vars.packages }} + /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': + exit-status: 0 + stdout: + {{range $pkg := $pkgs}} + - {{ $pkg }} + {{end}} + +# Ensure correct R version + "/opt/R/{{.Env.R_VERSION}}/bin/R --version": + title: r_version_match + exit-status: 0 + stdout: [ + "/{{.Env.R_VERSION}}/" + ] +# Ensure correct python version + "/opt/python/{{.Env.PYTHON_VERSION}}/bin/python --version": + title: python_version_matches + exit-status: 0 + stdout: [ + "/{{ .Env.PYTHON_VERSION }}/" + ] \ No newline at end of file diff --git a/r-session-complete/bionic/test/goss_vars.yaml b/r-session-complete/bionic/test/goss_vars.yaml new file mode 100644 index 000000000..439a4dd57 --- /dev/null +++ b/r-session-complete/bionic/test/goss_vars.yaml @@ -0,0 +1,7 @@ +packages: + - "odbc" + - "devtools" + - "shiny" + - "rmarkdown" + - "plumber" + \ No newline at end of file diff --git a/r-session-complete/centos7/docker-compose.test.yml b/r-session-complete/centos7/docker-compose.test.yml index d7df72404..54c4f4ebf 100644 --- a/r-session-complete/centos7/docker-compose.test.yml +++ b/r-session-complete/centos7/docker-compose.test.yml @@ -11,3 +11,4 @@ services: volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" + - "./test/vars.yaml:/tmp/vars.yaml" \ No newline at end of file From 5f0a3a9b6c2e66a54ff8eaeebf488b14d3737a19 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 19:29:31 -0400 Subject: [PATCH 08/23] r packages --- r-session-complete/bionic/test/goss.yaml | 6 ++-- r-session-complete/bionic/test/goss_vars.yaml | 32 ++++++++++++++++++- r-session-complete/centos7/.env | 0 .../centos7/docker-compose.test.yml | 4 ++- .../centos7/test/goss_vars.yaml | 6 ++++ 5 files changed, 43 insertions(+), 5 deletions(-) create mode 100644 r-session-complete/centos7/.env create mode 100644 r-session-complete/centos7/test/goss_vars.yaml diff --git a/r-session-complete/bionic/test/goss.yaml b/r-session-complete/bionic/test/goss.yaml index d5875ad82..4797d38e8 100644 --- a/r-session-complete/bionic/test/goss.yaml +++ b/r-session-complete/bionic/test/goss.yaml @@ -14,14 +14,14 @@ command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 - {{ $pkgs := .Vars.packages }} + # Ensure all R Packages are installed + {{ $pkgs := .Vars.RPackages }} /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': exit-status: 0 stdout: - {{range $pkg := $pkgs}} + {{ range $pkg := $pkgs }} - {{ $pkg }} {{end}} - # Ensure correct R version "/opt/R/{{.Env.R_VERSION}}/bin/R --version": title: r_version_match diff --git a/r-session-complete/bionic/test/goss_vars.yaml b/r-session-complete/bionic/test/goss_vars.yaml index 439a4dd57..e3bae7b43 100644 --- a/r-session-complete/bionic/test/goss_vars.yaml +++ b/r-session-complete/bionic/test/goss_vars.yaml @@ -1,7 +1,37 @@ -packages: +RPackages: - "odbc" - "devtools" - "shiny" - "rmarkdown" - "plumber" +PythonPackages: + - "altair" + - "beautifulsoup4" + - "bokeh" + - "cloudpickle" + - "cython" + - "dash" + - "dask" + - "flask" + - "gensim" + - "keras" + - "matplotlib" + - "nltk" + - "numpy" + - "pandas" + - "pillow" + - "plotly" + - "pyarrow" + - "requests" + - "scipy" + - "scikit-image " + - "scikit-learn " + - "scrapy " + - "seaborn " + - "spacy " + - "sqlalchemy " + - "statsmodels " + - "streamlit " + - "tensorflow " + - "xgboost" \ No newline at end of file diff --git a/r-session-complete/centos7/.env b/r-session-complete/centos7/.env new file mode 100644 index 000000000..e69de29bb diff --git a/r-session-complete/centos7/docker-compose.test.yml b/r-session-complete/centos7/docker-compose.test.yml index 54c4f4ebf..cede3e437 100644 --- a/r-session-complete/centos7/docker-compose.test.yml +++ b/r-session-complete/centos7/docker-compose.test.yml @@ -8,7 +8,9 @@ services: environment: # uses .env by default - RSP_VERSION + - R_VERSION + - PYTHON_VERSION volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" - - "./test/vars.yaml:/tmp/vars.yaml" \ No newline at end of file + - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" \ No newline at end of file diff --git a/r-session-complete/centos7/test/goss_vars.yaml b/r-session-complete/centos7/test/goss_vars.yaml new file mode 100644 index 000000000..4c0fff8a4 --- /dev/null +++ b/r-session-complete/centos7/test/goss_vars.yaml @@ -0,0 +1,6 @@ +RPackages: + - "odbc" + - "devtools" + - "shiny" + - "rmarkdown" + - "plumber" From 4aff38540e12014639035b06c574ed62bb6a9a98 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 19:48:28 -0400 Subject: [PATCH 09/23] Delete goss-image-tests.yaml --- .github/workflows/goss-image-tests.yaml | 13 ------------- 1 file changed, 13 deletions(-) delete mode 100644 .github/workflows/goss-image-tests.yaml diff --git a/.github/workflows/goss-image-tests.yaml b/.github/workflows/goss-image-tests.yaml deleted file mode 100644 index a8e0d2c2f..000000000 --- a/.github/workflows/goss-image-tests.yaml +++ /dev/null @@ -1,13 +0,0 @@ -name: goss-secrets-test -on: push -jobs: - job1: - runs-on: ubuntu-latest - steps: - - name: Test - run: | - echo secrets-configured - env: - RSC_LICENSE: ${{ secrets.RSC_LICENSE }} - RSP_LICENSE: ${{ secrets.RSP_LICENSE }} - RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} From 34d04dfe10165ee8e023f3882f0b6ac70f769bb4 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 6 Jul 2021 20:35:50 -0400 Subject: [PATCH 10/23] alternate r version --- .github/workflows/goss-image-tests.yaml | 13 -------- .vscode/settings.json | 3 ++ .../bionic/docker-compose.test.yml | 2 +- r-session-complete/bionic/test/goss.yaml | 4 +-- r-session-complete/bionic/test/goss_vars.yaml | 32 +------------------ r-session-complete/centos7/.env | 4 +++ r-session-complete/centos7/test/goss.yaml | 28 ++++++++++++++++ server-pro/test/goss.yaml | 3 -- 8 files changed, 39 insertions(+), 50 deletions(-) delete mode 100644 .github/workflows/goss-image-tests.yaml create mode 100644 .vscode/settings.json diff --git a/.github/workflows/goss-image-tests.yaml b/.github/workflows/goss-image-tests.yaml deleted file mode 100644 index a8e0d2c2f..000000000 --- a/.github/workflows/goss-image-tests.yaml +++ /dev/null @@ -1,13 +0,0 @@ -name: goss-secrets-test -on: push -jobs: - job1: - runs-on: ubuntu-latest - steps: - - name: Test - run: | - echo secrets-configured - env: - RSC_LICENSE: ${{ secrets.RSC_LICENSE }} - RSP_LICENSE: ${{ secrets.RSP_LICENSE }} - RSPM_LICENSE: ${{ secrets.RSPM_LICENSE }} diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 000000000..615aafb03 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "python.pythonPath": "/usr/bin/python3" +} \ No newline at end of file diff --git a/r-session-complete/bionic/docker-compose.test.yml b/r-session-complete/bionic/docker-compose.test.yml index dded891b4..cede3e437 100644 --- a/r-session-complete/bionic/docker-compose.test.yml +++ b/r-session-complete/bionic/docker-compose.test.yml @@ -2,7 +2,7 @@ version: '2.3' services: sut: - image: "6e2d311047c4" + image: $IMAGE_NAME command: /run_tests.sh entrypoint: [] environment: diff --git a/r-session-complete/bionic/test/goss.yaml b/r-session-complete/bionic/test/goss.yaml index 4797d38e8..7d9cf5b66 100644 --- a/r-session-complete/bionic/test/goss.yaml +++ b/r-session-complete/bionic/test/goss.yaml @@ -9,12 +9,11 @@ file: /opt/rstudio-drivers: exists: true filetype: directory - command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 - # Ensure all R Packages are installed +# Ensure all R Packages are installed {{ $pkgs := .Vars.RPackages }} /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': exit-status: 0 @@ -29,6 +28,7 @@ command: stdout: [ "/{{.Env.R_VERSION}}/" ] + # Ensure correct python version "/opt/python/{{.Env.PYTHON_VERSION}}/bin/python --version": title: python_version_matches diff --git a/r-session-complete/bionic/test/goss_vars.yaml b/r-session-complete/bionic/test/goss_vars.yaml index e3bae7b43..9618c6a53 100644 --- a/r-session-complete/bionic/test/goss_vars.yaml +++ b/r-session-complete/bionic/test/goss_vars.yaml @@ -4,34 +4,4 @@ RPackages: - "shiny" - "rmarkdown" - "plumber" -PythonPackages: - - "altair" - - "beautifulsoup4" - - "bokeh" - - "cloudpickle" - - "cython" - - "dash" - - "dask" - - "flask" - - "gensim" - - "keras" - - "matplotlib" - - "nltk" - - "numpy" - - "pandas" - - "pillow" - - "plotly" - - "pyarrow" - - "requests" - - "scipy" - - "scikit-image " - - "scikit-learn " - - "scrapy " - - "seaborn " - - "spacy " - - "sqlalchemy " - - "statsmodels " - - "streamlit " - - "tensorflow " - - "xgboost" - \ No newline at end of file + diff --git a/r-session-complete/centos7/.env b/r-session-complete/centos7/.env index e69de29bb..9b8735947 100644 --- a/r-session-complete/centos7/.env +++ b/r-session-complete/centos7/.env @@ -0,0 +1,4 @@ +R_VERSION=4.0.2 +PYTHON_VERSION=3.7.7 +DRIVERS_VERSION=1.7.0 +RSP_VERSION=1.4.1717-3 \ No newline at end of file diff --git a/r-session-complete/centos7/test/goss.yaml b/r-session-complete/centos7/test/goss.yaml index 3481757f8..4797d38e8 100644 --- a/r-session-complete/centos7/test/goss.yaml +++ b/r-session-complete/centos7/test/goss.yaml @@ -3,8 +3,36 @@ file: exists: true /usr/lib/rstudio-server/bin/rsession: exists: true + /opt/code-server/: + exists: true + filetype: directory + /opt/rstudio-drivers: + exists: true + filetype: directory command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 + # Ensure all R Packages are installed + {{ $pkgs := .Vars.RPackages }} + /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': + exit-status: 0 + stdout: + {{ range $pkg := $pkgs }} + - {{ $pkg }} + {{end}} +# Ensure correct R version + "/opt/R/{{.Env.R_VERSION}}/bin/R --version": + title: r_version_match + exit-status: 0 + stdout: [ + "/{{.Env.R_VERSION}}/" + ] +# Ensure correct python version + "/opt/python/{{.Env.PYTHON_VERSION}}/bin/python --version": + title: python_version_matches + exit-status: 0 + stdout: [ + "/{{ .Env.PYTHON_VERSION }}/" + ] \ No newline at end of file diff --git a/server-pro/test/goss.yaml b/server-pro/test/goss.yaml index b211af53f..04ca7738b 100644 --- a/server-pro/test/goss.yaml +++ b/server-pro/test/goss.yaml @@ -23,9 +23,6 @@ file: /opt/R/{{.Env.ALT_R_VERSION}}/bin/R: exists: true filetype: file - /opt/R/{{.Env.R_VERSION}}/bin/R: - exists: true - filetype: file /opt/python/{{.Env.PYTHON_VERSION}}/bin/python: exists: true filetype: symlink From c436938404db8a57d5966446121ca36632c73d64 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 08:53:41 -0400 Subject: [PATCH 11/23] licenses and spacing --- .github/workflows/build-preview.yaml | 5 ++++- connect/test/goss.yaml | 4 ++-- r-session-complete/bionic/test/goss.yaml | 6 +++++- r-session-complete/centos7/test/goss.yaml | 7 +++++-- server-pro/test/goss.yaml | 8 ++------ 5 files changed, 18 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build-preview.yaml b/.github/workflows/build-preview.yaml index c14c1ed2c..5b64d2b58 100644 --- a/.github/workflows/build-preview.yaml +++ b/.github/workflows/build-preview.yaml @@ -86,8 +86,11 @@ jobs: RSP_VERSION: ${{ steps.version.outputs.VERSION }} RSC_VERSION: ${{ steps.version.outputs.VERSION }} RSPM_VERSION: ${{ steps.version.outputs.VERSION }} + # RSP_LICENSE: ${{secrets.RSP_LICENSE}} + # RSC_LICENSE: ${{secrets.RSC_LICENSE}} + # RSPM_LICENSE: ${{secrets.RSPM_LICENSE}} run: | - docker-compose -f ./${{ matrix.config.dir }}/docker-compose.test.yml run sut + docker-compose -f ./${{ matrix.config.dir }}/docker- compose.test.yml run sut - name: Login to Docker Hub if: ${{ github.ref == 'refs/heads/main' }} diff --git a/connect/test/goss.yaml b/connect/test/goss.yaml index 2607ac695..b90a4dbbd 100644 --- a/connect/test/goss.yaml +++ b/connect/test/goss.yaml @@ -44,13 +44,13 @@ command: stdout: [ "/{{ .Env.RSC_VERSION }}/" ] - + # Goss times out after 10 seconds "timeout --signal=SIGINT 7 /opt/rstudio-connect/bin/connect --config /etc/rstudio-connect/rstudio-connect.gcfg": title: connect_starts # The timeout should stop connect, not a failure exit-status: 124 - + # Ensure correct R version "/opt/R/{{ .Env.R_VERSION }}/bin/R --version": title: r_version_match diff --git a/r-session-complete/bionic/test/goss.yaml b/r-session-complete/bionic/test/goss.yaml index 7d9cf5b66..8600b3cfc 100644 --- a/r-session-complete/bionic/test/goss.yaml +++ b/r-session-complete/bionic/test/goss.yaml @@ -9,10 +9,12 @@ file: /opt/rstudio-drivers: exists: true filetype: directory + command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 + # Ensure all R Packages are installed {{ $pkgs := .Vars.RPackages }} /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': @@ -21,6 +23,7 @@ command: {{ range $pkg := $pkgs }} - {{ $pkg }} {{end}} + # Ensure correct R version "/opt/R/{{.Env.R_VERSION}}/bin/R --version": title: r_version_match @@ -35,4 +38,5 @@ command: exit-status: 0 stdout: [ "/{{ .Env.PYTHON_VERSION }}/" - ] \ No newline at end of file + ] + \ No newline at end of file diff --git a/r-session-complete/centos7/test/goss.yaml b/r-session-complete/centos7/test/goss.yaml index 4797d38e8..ce2b45279 100644 --- a/r-session-complete/centos7/test/goss.yaml +++ b/r-session-complete/centos7/test/goss.yaml @@ -14,7 +14,8 @@ command: "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/3.7.7/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 - # Ensure all R Packages are installed + +# Ensure all R Packages are installed {{ $pkgs := .Vars.RPackages }} /opt/R/{{ .Env.R_VERSION }}/bin/R --slave -e 'library()' | cut -f 1 -d ' ' | grep -v '^Packages$' | grep -v '^$': exit-status: 0 @@ -22,6 +23,7 @@ command: {{ range $pkg := $pkgs }} - {{ $pkg }} {{end}} + # Ensure correct R version "/opt/R/{{.Env.R_VERSION}}/bin/R --version": title: r_version_match @@ -29,10 +31,11 @@ command: stdout: [ "/{{.Env.R_VERSION}}/" ] + # Ensure correct python version "/opt/python/{{.Env.PYTHON_VERSION}}/bin/python --version": title: python_version_matches exit-status: 0 stdout: [ "/{{ .Env.PYTHON_VERSION }}/" - ] \ No newline at end of file + ] diff --git a/server-pro/test/goss.yaml b/server-pro/test/goss.yaml index 04ca7738b..9853e8f6d 100644 --- a/server-pro/test/goss.yaml +++ b/server-pro/test/goss.yaml @@ -55,7 +55,6 @@ command: "touch /var/log/rstudio-server.log": title: server-pro_server_log_creates exit-status: 0 - # Check product version "rstudio-server version": title: server-pro_version_matches @@ -64,11 +63,9 @@ command: "/{{ .Env.RSP_VERSION }}/", "/Workbench/" ] - "echo '{ \"cells\": [], \"metadata\": {}, \"nbformat\": 4, \"nbformat_minor\": 2}' | /opt/python/jupyter/bin/jupyter nbconvert --to notebook --stdin --stdout": title: jupyter_works exit-status: 0 - # Ensure correct python version "/opt/python/3.8.10/bin/python --version": title: alternate_python_version_matches @@ -89,10 +86,9 @@ command: stdout: [ "/{{.Env.JUPYTER_PYTHON_VERSION}}/" ] - - "which openssl": + "which openssl": title: uses_system_openssl exit-status: 0 stdout: [ "/usr/bin/openssl" - ] \ No newline at end of file + ] From ab29888ebf9de39a5ac5b700f456bdf4737a5031 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 09:01:25 -0400 Subject: [PATCH 12/23] docker compose spacing --- .github/workflows/build-preview.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-preview.yaml b/.github/workflows/build-preview.yaml index 5b64d2b58..53d3a6d44 100644 --- a/.github/workflows/build-preview.yaml +++ b/.github/workflows/build-preview.yaml @@ -90,7 +90,7 @@ jobs: # RSC_LICENSE: ${{secrets.RSC_LICENSE}} # RSPM_LICENSE: ${{secrets.RSPM_LICENSE}} run: | - docker-compose -f ./${{ matrix.config.dir }}/docker- compose.test.yml run sut + docker-compose -f ./${{ matrix.config.dir }}/docker-compose.test.yml run sut - name: Login to Docker Hub if: ${{ github.ref == 'refs/heads/main' }} From 7c645268dd546d9dd10f9b3ca0a5d041d818b0ef Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 11:09:22 -0400 Subject: [PATCH 13/23] docker compose --- .github/workflows/build-preview.yaml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/build-preview.yaml b/.github/workflows/build-preview.yaml index 53d3a6d44..c14c1ed2c 100644 --- a/.github/workflows/build-preview.yaml +++ b/.github/workflows/build-preview.yaml @@ -86,9 +86,6 @@ jobs: RSP_VERSION: ${{ steps.version.outputs.VERSION }} RSC_VERSION: ${{ steps.version.outputs.VERSION }} RSPM_VERSION: ${{ steps.version.outputs.VERSION }} - # RSP_LICENSE: ${{secrets.RSP_LICENSE}} - # RSC_LICENSE: ${{secrets.RSC_LICENSE}} - # RSPM_LICENSE: ${{secrets.RSPM_LICENSE}} run: | docker-compose -f ./${{ matrix.config.dir }}/docker-compose.test.yml run sut From f5a356fb94142ca77abd310b78e25fe27127f755 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 11:34:45 -0400 Subject: [PATCH 14/23] 'which' spacing --- server-pro/test/goss.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server-pro/test/goss.yaml b/server-pro/test/goss.yaml index 9853e8f6d..67086e22c 100644 --- a/server-pro/test/goss.yaml +++ b/server-pro/test/goss.yaml @@ -86,7 +86,7 @@ command: stdout: [ "/{{.Env.JUPYTER_PYTHON_VERSION}}/" ] - "which openssl": + "which openssl": title: uses_system_openssl exit-status: 0 stdout: [ From 7c7e5cbb5b7267705fce25e1b205fc98d9949fee Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 13:15:25 -0400 Subject: [PATCH 15/23] new lines --- r-session-complete/centos7/docker-compose.test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/r-session-complete/centos7/docker-compose.test.yml b/r-session-complete/centos7/docker-compose.test.yml index cede3e437..8cf1a18d4 100644 --- a/r-session-complete/centos7/docker-compose.test.yml +++ b/r-session-complete/centos7/docker-compose.test.yml @@ -13,4 +13,4 @@ services: volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" - - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" \ No newline at end of file + - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" From e6b0dc2e0a3245024673868253edaac00a974c67 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 13:47:04 -0400 Subject: [PATCH 16/23] newlines --- .vscode/settings.json | 2 +- connect/.env | 2 +- connect/test/goss.yaml | 2 +- package-manager/.env | 2 +- package-manager/test/goss.yaml | 2 +- r-session-complete/bionic/.env | 2 +- r-session-complete/bionic/docker-compose.test.yml | 2 +- r-session-complete/bionic/test/goss.yaml | 1 - r-session-complete/centos7/.env | 2 +- 9 files changed, 8 insertions(+), 9 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 615aafb03..99acc159f 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,3 +1,3 @@ { "python.pythonPath": "/usr/bin/python3" -} \ No newline at end of file +} diff --git a/connect/.env b/connect/.env index 468cd891d..f64f4543c 100644 --- a/connect/.env +++ b/connect/.env @@ -1,3 +1,3 @@ RSC_VERSION=1.8.8.2 R_VERSION=3.6.2 -PYTHON_VERSION=3.6.5 \ No newline at end of file +PYTHON_VERSION=3.6.5 diff --git a/connect/test/goss.yaml b/connect/test/goss.yaml index b90a4dbbd..c0eb7642a 100644 --- a/connect/test/goss.yaml +++ b/connect/test/goss.yaml @@ -65,4 +65,4 @@ command: exit-status: 0 stderr: [ "/{{ .Env.PYTHON_VERSION }}/" - ] \ No newline at end of file + ] diff --git a/package-manager/.env b/package-manager/.env index 8a174c15d..7d61bf69d 100644 --- a/package-manager/.env +++ b/package-manager/.env @@ -1,2 +1,2 @@ RSPM_VERSION=1.2.2.1-17 -R_VERSION=3.6.2 \ No newline at end of file +R_VERSION=3.6.2 diff --git a/package-manager/test/goss.yaml b/package-manager/test/goss.yaml index 5116bd9e5..5ecb883cf 100644 --- a/package-manager/test/goss.yaml +++ b/package-manager/test/goss.yaml @@ -52,4 +52,4 @@ command: exit-status: 0 stdout: [ "/{{ .Env.R_VERSION }}/" - ] \ No newline at end of file + ] diff --git a/r-session-complete/bionic/.env b/r-session-complete/bionic/.env index 9b8735947..87f5e5796 100644 --- a/r-session-complete/bionic/.env +++ b/r-session-complete/bionic/.env @@ -1,4 +1,4 @@ R_VERSION=4.0.2 PYTHON_VERSION=3.7.7 DRIVERS_VERSION=1.7.0 -RSP_VERSION=1.4.1717-3 \ No newline at end of file +RSP_VERSION=1.4.1717-3 diff --git a/r-session-complete/bionic/docker-compose.test.yml b/r-session-complete/bionic/docker-compose.test.yml index cede3e437..8cf1a18d4 100644 --- a/r-session-complete/bionic/docker-compose.test.yml +++ b/r-session-complete/bionic/docker-compose.test.yml @@ -13,4 +13,4 @@ services: volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" - - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" \ No newline at end of file + - "./test/goss_vars.yaml:/tmp/goss_vars.yaml" diff --git a/r-session-complete/bionic/test/goss.yaml b/r-session-complete/bionic/test/goss.yaml index 8600b3cfc..ce2b45279 100644 --- a/r-session-complete/bionic/test/goss.yaml +++ b/r-session-complete/bionic/test/goss.yaml @@ -39,4 +39,3 @@ command: stdout: [ "/{{ .Env.PYTHON_VERSION }}/" ] - \ No newline at end of file diff --git a/r-session-complete/centos7/.env b/r-session-complete/centos7/.env index 9b8735947..87f5e5796 100644 --- a/r-session-complete/centos7/.env +++ b/r-session-complete/centos7/.env @@ -1,4 +1,4 @@ R_VERSION=4.0.2 PYTHON_VERSION=3.7.7 DRIVERS_VERSION=1.7.0 -RSP_VERSION=1.4.1717-3 \ No newline at end of file +RSP_VERSION=1.4.1717-3 From 18727479f0ac417061722e0259405e16ed246ac8 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 16:04:36 -0400 Subject: [PATCH 17/23] env var consistency --- .vscode/settings.json | 3 --- server-pro/.env | 5 ++--- server-pro/test/goss.yaml | 6 +++--- 3 files changed, 5 insertions(+), 9 deletions(-) delete mode 100644 .vscode/settings.json diff --git a/.vscode/settings.json b/.vscode/settings.json deleted file mode 100644 index 99acc159f..000000000 --- a/.vscode/settings.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "python.pythonPath": "/usr/bin/python3" -} diff --git a/server-pro/.env b/server-pro/.env index 6c16034f6..04ac9ce61 100644 --- a/server-pro/.env +++ b/server-pro/.env @@ -2,8 +2,7 @@ RSP_VERSION=1.4.1717-3 RSP_DOWNLOAD_URL=https://download2.rstudio.org/server/bionic/amd64 RSP_NAME=rstudio-workbench PYTHON_VERSION=3.9.5 -ALT_PYTHON_VERSION=3.8.10 +PYTHON_VERSION_ALT=3.8.10 JUPYTER_PYTHON_VERSION=3.8.10 -ALT_R_VERSION=4.1.0 +R_VERSION_ALT=4.1.0 R_VERSION=3.6.2 - diff --git a/server-pro/test/goss.yaml b/server-pro/test/goss.yaml index 67086e22c..35b444faf 100644 --- a/server-pro/test/goss.yaml +++ b/server-pro/test/goss.yaml @@ -20,13 +20,13 @@ file: exists: false /usr/lib/rstudio-server: exists: true - /opt/R/{{.Env.ALT_R_VERSION}}/bin/R: + /opt/R/{{.Env.R_VERSION_ALT}}/bin/R: exists: true filetype: file /opt/python/{{.Env.PYTHON_VERSION}}/bin/python: exists: true filetype: symlink - /opt/python/{{.Env.ALT_PYTHON_VERSION}}/bin/python: + /opt/python/{{.Env.PYTHON_VERSION_ALT}}/bin/python: exists: true filetype: symlink /opt/python/jupyter/bin/python: @@ -71,7 +71,7 @@ command: title: alternate_python_version_matches exit-status: 0 stdout: [ - "/{{.Env.ALT_PYTHON_VERSION}}/" + "/{{.Env.PYTHON_VERSION_ALT}}/" ] # Ensure correct python version "/opt/python/3.9.5/bin/python --version": From ec1df21aa28875fd4a739a577a2f2760836cad4a Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Wed, 7 Jul 2021 16:10:42 -0400 Subject: [PATCH 18/23] update docker compose --- server-pro/Dockerfile | 10 +++++----- server-pro/docker-compose.test.yml | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/server-pro/Dockerfile b/server-pro/Dockerfile index 358617b70..3aa2cbcfa 100644 --- a/server-pro/Dockerfile +++ b/server-pro/Dockerfile @@ -81,16 +81,16 @@ RUN curl -O https://repo.anaconda.com/miniconda/Miniconda3-4.7.12.1-Linux-x86_64 # Install another Python --------------------------------------------------------------# -ARG ALT_PYTHON_VERSION=3.8.10 +ARG PYTHON_VERSION_ALT=3.8.10 RUN curl -O https://repo.anaconda.com/miniconda/Miniconda3-4.7.12.1-Linux-x86_64.sh && \ - bash Miniconda3-4.7.12.1-Linux-x86_64.sh -bp /opt/python/${ALT_PYTHON_VERSION} && \ - /opt/python/${ALT_PYTHON_VERSION}/bin/conda install -y python==${ALT_PYTHON_VERSION} && \ - /opt/python/${ALT_PYTHON_VERSION}/bin/pip install \ + bash Miniconda3-4.7.12.1-Linux-x86_64.sh -bp /opt/python/${PYTHON_VERSION_ALT} && \ + /opt/python/${PYTHON_VERSION_ALT}/bin/conda install -y python==${PYTHON_VERSION_ALT} && \ + /opt/python/${PYTHON_VERSION_ALT}/bin/pip install \ ipykernel \ virtualenv \ && \ rm -rf Miniconda3-*-Linux-x86_64.sh && \ - /opt/python/${ALT_PYTHON_VERSION}/bin/python -m ipykernel install --name py${ALT_PYTHON_VERSION} --display-name "Python ${ALT_PYTHON_VERSION}" + /opt/python/${PYTHON_VERSION_ALT}/bin/python -m ipykernel install --name py${PYTHON_VERSION_ALT} --display-name "Python ${PYTHON_VERSION_ALT}" # Runtime settings ------------------------------------------------------------# ARG TINI_VERSION=0.18.0 diff --git a/server-pro/docker-compose.test.yml b/server-pro/docker-compose.test.yml index 965392460..772b6b735 100644 --- a/server-pro/docker-compose.test.yml +++ b/server-pro/docker-compose.test.yml @@ -10,9 +10,9 @@ services: - RSP_VERSION - R_VERSION - PYTHON_VERSION - - ALT_PYTHON_VERSION + - PYTHON_VERSION_ALT - JUPYTER_PYTHON_VERSION - - ALT_R_VERSION + - R_VERSION_ALT volumes: - "./test/run_tests.sh:/run_tests.sh" - "./test/goss.yaml:/tmp/goss.yaml" From 8a0371f4a5a7b612286da3182fa5ff65baeaf438 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Thu, 8 Jul 2021 14:11:51 -0400 Subject: [PATCH 19/23] add R_VERSION environment variable rspm --- package-manager/test/goss.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package-manager/test/goss.yaml b/package-manager/test/goss.yaml index 5ecb883cf..392ad2eec 100644 --- a/package-manager/test/goss.yaml +++ b/package-manager/test/goss.yaml @@ -47,7 +47,7 @@ command: exit-status: 0 # Ensure correct R version - "/opt/R/3.6.2/bin/R --version": + "/opt/R/{{ .Env.R_VERSION }}/bin/R --version": title: r_version_match exit-status: 0 stdout: [ From 202c5ba7ef1f1752e6c2732619c35fd27f427b4a Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Thu, 8 Jul 2021 16:36:48 -0400 Subject: [PATCH 20/23] odbc --- r-session-complete/bionic/docker-compose.test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/r-session-complete/bionic/docker-compose.test.yml b/r-session-complete/bionic/docker-compose.test.yml index 8cf1a18d4..89e7219e3 100644 --- a/r-session-complete/bionic/docker-compose.test.yml +++ b/r-session-complete/bionic/docker-compose.test.yml @@ -2,7 +2,7 @@ version: '2.3' services: sut: - image: $IMAGE_NAME + image: 6e2d311047c4 command: /run_tests.sh entrypoint: [] environment: From bc71ed8f559fc1b63e350c12ab6d0c7403322d3b Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Thu, 8 Jul 2021 16:37:42 -0400 Subject: [PATCH 21/23] odbc --- r-session-complete/bionic/docker-compose.test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/r-session-complete/bionic/docker-compose.test.yml b/r-session-complete/bionic/docker-compose.test.yml index 89e7219e3..8cf1a18d4 100644 --- a/r-session-complete/bionic/docker-compose.test.yml +++ b/r-session-complete/bionic/docker-compose.test.yml @@ -2,7 +2,7 @@ version: '2.3' services: sut: - image: 6e2d311047c4 + image: $IMAGE_NAME command: /run_tests.sh entrypoint: [] environment: From 6907e61fdc5e349516cb086092c956bde8146772 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Thu, 8 Jul 2021 17:31:50 -0400 Subject: [PATCH 22/23] test odbc --- r-session-complete/centos7/test/goss_vars.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/r-session-complete/centos7/test/goss_vars.yaml b/r-session-complete/centos7/test/goss_vars.yaml index 4c0fff8a4..285e45fdb 100644 --- a/r-session-complete/centos7/test/goss_vars.yaml +++ b/r-session-complete/centos7/test/goss_vars.yaml @@ -1,5 +1,4 @@ RPackages: - - "odbc" - "devtools" - "shiny" - "rmarkdown" From 06fc8bbc039724776576e8d012037c0777f7f7d6 Mon Sep 17 00:00:00 2001 From: Nahara <41586691+nahara7@users.noreply.github.com> Date: Tue, 13 Jul 2021 11:39:39 -0400 Subject: [PATCH 23/23] check rspm binary in centos with odbc package --- r-session-complete/centos7/test/goss_vars.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/r-session-complete/centos7/test/goss_vars.yaml b/r-session-complete/centos7/test/goss_vars.yaml index 285e45fdb..4c0fff8a4 100644 --- a/r-session-complete/centos7/test/goss_vars.yaml +++ b/r-session-complete/centos7/test/goss_vars.yaml @@ -1,4 +1,5 @@ RPackages: + - "odbc" - "devtools" - "shiny" - "rmarkdown"