{"id":14068175,"url":"https://github.com/slopp/rsc-ci-test","last_synced_at":"2025-12-30T14:17:39.475Z","repository":{"id":94927408,"uuid":"104402325","full_name":"slopp/rsc-ci-test","owner":"slopp","description":null,"archived":false,"fork":false,"pushed_at":"2017-12-06T20:23:15.000Z","size":7,"stargazers_count":8,"open_issues_count":0,"forks_count":1,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-08-13T07:14:20.292Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/slopp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2017-09-21T21:49:57.000Z","updated_at":"2022-05-18T18:20:17.000Z","dependencies_parsed_at":"2023-04-15T09:21:44.240Z","dependency_job_id":null,"html_url":"https://github.com/slopp/rsc-ci-test","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slopp%2Frsc-ci-test","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slopp%2Frsc-ci-test/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slopp%2Frsc-ci-test/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/slopp%2Frsc-ci-test/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/slopp","download_url":"https://codeload.github.com/slopp/rsc-ci-test/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228075764,"owners_count":17865547,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-13T07:06:00.293Z","updated_at":"2025-12-30T14:17:39.415Z","avatar_url":"https://github.com/slopp.png","language":"R","funding_links":[],"categories":["R"],"sub_categories":[],"readme":"# Continous Integration + Connect Deployment\n\nThis repository shows you how to setup travis to deploy content to RSC. \n\nYou will need:\n\n1. packrat \u0026 rsconnect packages \n2. Git repository with a working shiny app\n3. A publisher account on a RStudio Connect server\n\n\nSteps:\n\n\n1. If you have not already, link the IDE to Connect via your publisher account. See the user guide for details.\n\n2. Enter the command:\n`rsconnect:::rsconnectConfigDir()`\n\n3. Navigate to the resulting directory. It should look something like:\n\n```\n-\u003e tree\n.\n├── accounts\n│   └── colorado.rstudio.com\n│       └── sean.dcf\n└── servers\n    └── colorado.rstudio.com.dcf\n```\n\n4. Copy the 2 dcf files into the repository. Note that one file has the name of the server (colorado.rstudio.com.dcf) and the other file has the name of the account (sean.dcf)\n\n5. Open the account dcf file. (In my case, the file named sean.dcf). The file consists of key-value pairs in the form: `key: value`. For the keys `token` and `private_key`, carefully copy the values to safe location for later, and then remove them from the file. *DON'T* remove the key, at the end you should have a file like:\n\n```\nusername: sean\naccountId: 1\ntoken: \nserver: colorado.rstudio.com\nprivate_key: \n```\n\n6. Copy the `setup.R` file from this repo into your repo. At the top of the file, change the account and server values to match your account and server dcf files:\n\n```\n# parameters name\naccount \u003c- 'sean'\nserver \u003c- 'colorado.rstudio.com'\n...\n```\n\n7. Copy the `deploy.R` file from this repo into your repo. Edit the file to properly setup your deployment:\n\n```\nlibrary(rsconnect)\nrsconnect::deployApp(\n  appDir = \".\",\n  appFiles = c('app.R'),             # change this to include all the files your app needs!\n  appPrimaryDoc = 'app.R',          \n  appName = \"CI-Deployed\",           # this is the name your app will have on Connect\n  account = \"sean\",                  # this is the same account name as your account dcf file\n  server = \"colorado.rstudio.com\",   # this is the same server name as your server dcf file\n  logLevel = 'verbose'\n)\n```\n\n8. Run the command `packrat::.snapshotImpl(\".\", snapshot.sources = FALSE)`. This creates a packrat directory with a `packrat.lock` file.\n\n9. Copy the `.travis.yml` file from this repo to yours. The only thing you might need to change is the version of R at the top:\n\n```\ndist: trust\nlanguage: r\nsudo: false\nr: 3.3.3     # \u003c- change me!\n...\n```\n\n10. Log into travis and enable builds for your app's repository. In the settings for the repo, add two environment variables:\n  - `DEPLOY_KEY` : Copy the long private_key we saved earlier in step 5.\n  - `DEPLOY_TOKEN` : Copy the token we saved earlier in step 5.\n  \nYou're all set! The next time you push to this repository, travis will deploy your app to Connect!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslopp%2Frsc-ci-test","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fslopp%2Frsc-ci-test","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fslopp%2Frsc-ci-test/lists"}