diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000000000000000000000000000000000000..cdd2e7336f5fb285896a19f97b7f4cc9c1ac1a78
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,31 @@
+stages:
+  - check
+
+variables:
+  R_CI: "$CI_PROJECT_DIR/ci"
+  R_LIBS_USER: "$R_CI/lib"
+
+default:
+  tags: [docker]
+  image: rocker/verse:devel
+
+cache:
+  paths:
+    - $R_CI
+
+before_script:
+  - mkdir -p $R_LIBS_USER
+  - echo "R_LIBS='$R_LIBS_USER'" > .Renviron
+  - R -q -e 'remotes::install_deps(dependencies = TRUE)'
+
+check:
+  stage: check
+  script:
+  - tlmgr update --self && tlmgr install ec epstopdf-pkg
+  - R -q -e 'remotes::update_packages("rcmdcheck")'
+  - R -q -e 'rcmdcheck::rcmdcheck(args = "--as-cran", error_on = "error")'
+
+test_all:
+  stage: check
+  script:
+  - R -q -e 'devtools::test()'