{"action":"created","comment":{"url":"https://api.github.com/repos/dcos/dcos-docs/pulls/comments/73566191","id":73566191,"diff_hunk":"@@ -0,0 +1,222 @@\n+---\n+post_title: Creating A Universe Package\n+nav_title: Creating\n+menu_order: 005\n+---\n+\n+You can create your own package for the DC/OS Universe. [Universe](https://github.com/mesosphere/universe) is the DC/OS package repository that contains services like Spark, Cassandra, Jenkins, and many others.  \n+\n+Packages are published to the Mesosphere Universe repository on GitHub. At their simplest, DC/OS packages are bundled containerized apps that can be deployed onto a cluster. \n+\n+## Getting Started\n+\n+1.  Install these prerequisite tools.\n+    \n+    -  Install the DC/OS and the DC/OS CLI using this [guide](/docs/1.7/administration/installing/). You must have at least 1 [public agent](https://docs.mesosphere.com/1.7/overview/concepts/#public) node.\n+    -  Install [pip](https://pip.pypa.io/en/stable/installing.html#install-pip)\n+    -  Install jsonschema:\n+    \n+       ```bash\n+       $ pip install jsonschema\n+       ```\n+       \n+1.  Fork the [Universe](https://github.com/mesosphere/universe) repository, then clone the fork:\n+\n+    ```bash\n+    $ git clone https://github.com/<your-username>/universe\n+    ```\n+    \n+    As you look around the Universe repository you'll notice that the repository (`/repo/packages`) consists of packages arranged alphabetically. Each package consists of 4 JSON files:\n+    \n+    -  `config.json` -  configuration properties supported by the package, represented as a json-schema.\n+    -  `package.json` -  high-level metadata about the package.\n+    -  `marathon.json.mustache` - a [mustache](http://mustache.github.io/) template that when rendered will create a [Marathon](http://github.com/mesosphere/marathon) app definition capable of running your service.\n+    -  `resource.json` - contains all of the externally hosted resources (e.g. Docker images, HTTP objects and images) that are required to install the application.\n+\n+1.  Install the Universe repository pre-commit hooks.\n+\n+    ```bash\n+    $ bash scripts/install-git-hooks.sh\n+    ```\n+\n+1.  Create a new directory for the your package in `repo/packages/`. For example, to create a package named `helloworld` the structure is `repo/packages/H/helloworld/0`. The `0` directory corresponds to the release number of the package.  If you look at other packages in Universe, many have multiple releases (directories `0`, `1`, `2`, etc).\n+\n+Now, you're ready to start creating your package!  \n+\n+## Step One: Create package.json\n+\n+Every package in Universe must have a package.json file which specifies the high level metadata about the package. This file specifies the highest-level metadata about the package (comparable to a `package.json` in Node.js or `setup.py` in Python).\n+\n+Currently, a package can specify one of two values for `.packagingVersion`, either 2.0 or 3.0. The version is declared will dictate which other files are required for the complete package as well as the schemas all the files must adhere to. \n+\n+Below is a snippet that represents a version 2.0 package. See [`repo/meta/schema/package-schema.json`](https://github.com/mesosphere/universe/blob/version-3.x/repo/meta/schema/package-schema.json) for the full JSON schema outlining what properties are available for each corresponding version of a package.\n+\n+```javascript\n+{\n+  \"packagingVersion\": \"2.0\", // use either 2.0 or 3.0\n+  \"name\": \"foo\", // your package name\n+  \"version\": \"1.2.3\", // the version of the container that you are launching","path":"1.7/usage/managing-services/creating.md","position":58,"original_position":58,"commit_id":"caf12e879e3a96af468d28ee8eac23dbe6f8ffb4","original_commit_id":"caf12e879e3a96af468d28ee8eac23dbe6f8ffb4","user":{"login":"BenWhitehead","id":1754037,"avatar_url":"https://avatars.githubusercontent.com/u/1754037?v=3","gravatar_id":"","url":"https://api.github.com/users/BenWhitehead","html_url":"https://github.com/BenWhitehead","followers_url":"https://api.github.com/users/BenWhitehead/followers","following_url":"https://api.github.com/users/BenWhitehead/following{/other_user}","gists_url":"https://api.github.com/users/BenWhitehead/gists{/gist_id}","starred_url":"https://api.github.com/users/BenWhitehead/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenWhitehead/subscriptions","organizations_url":"https://api.github.com/users/BenWhitehead/orgs","repos_url":"https://api.github.com/users/BenWhitehead/repos","events_url":"https://api.github.com/users/BenWhitehead/events{/privacy}","received_events_url":"https://api.github.com/users/BenWhitehead/received_events","type":"User","site_admin":false},"body":"`s/the version of the container that you are launching/the version of the package/`\r\n\r\nThe version isn't necessarily correlated with the container down the line used to run the package.","created_at":"2016-08-04T17:28:40Z","updated_at":"2016-08-04T17:28:40Z","html_url":"https://github.com/dcos/dcos-docs/pull/431#discussion_r73566191","pull_request_url":"https://api.github.com/repos/dcos/dcos-docs/pulls/431","_links":{"self":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/comments/73566191"},"html":{"href":"https://github.com/dcos/dcos-docs/pull/431#discussion_r73566191"},"pull_request":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/431"}}},"pull_request":{"url":"https://api.github.com/repos/dcos/dcos-docs/pulls/431","id":76677646,"html_url":"https://github.com/dcos/dcos-docs/pull/431","diff_url":"https://github.com/dcos/dcos-docs/pull/431.diff","patch_url":"https://github.com/dcos/dcos-docs/pull/431.patch","issue_url":"https://api.github.com/repos/dcos/dcos-docs/issues/431","number":431,"state":"open","locked":false,"title":"Creating universe package","user":{"login":"joel-hamill","id":11722533,"avatar_url":"https://avatars.githubusercontent.com/u/11722533?v=3","gravatar_id":"","url":"https://api.github.com/users/joel-hamill","html_url":"https://github.com/joel-hamill","followers_url":"https://api.github.com/users/joel-hamill/followers","following_url":"https://api.github.com/users/joel-hamill/following{/other_user}","gists_url":"https://api.github.com/users/joel-hamill/gists{/gist_id}","starred_url":"https://api.github.com/users/joel-hamill/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joel-hamill/subscriptions","organizations_url":"https://api.github.com/users/joel-hamill/orgs","repos_url":"https://api.github.com/users/joel-hamill/repos","events_url":"https://api.github.com/users/joel-hamill/events{/privacy}","received_events_url":"https://api.github.com/users/joel-hamill/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-07-07T22:44:31Z","updated_at":"2016-08-04T17:28:41Z","closed_at":null,"merged_at":null,"merge_commit_sha":"313c5a93ceb1de8fafa569091d25d444f64f61f0","assignee":{"login":"BenWhitehead","id":1754037,"avatar_url":"https://avatars.githubusercontent.com/u/1754037?v=3","gravatar_id":"","url":"https://api.github.com/users/BenWhitehead","html_url":"https://github.com/BenWhitehead","followers_url":"https://api.github.com/users/BenWhitehead/followers","following_url":"https://api.github.com/users/BenWhitehead/following{/other_user}","gists_url":"https://api.github.com/users/BenWhitehead/gists{/gist_id}","starred_url":"https://api.github.com/users/BenWhitehead/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenWhitehead/subscriptions","organizations_url":"https://api.github.com/users/BenWhitehead/orgs","repos_url":"https://api.github.com/users/BenWhitehead/repos","events_url":"https://api.github.com/users/BenWhitehead/events{/privacy}","received_events_url":"https://api.github.com/users/BenWhitehead/received_events","type":"User","site_admin":false},"assignees":[{"login":"BenWhitehead","id":1754037,"avatar_url":"https://avatars.githubusercontent.com/u/1754037?v=3","gravatar_id":"","url":"https://api.github.com/users/BenWhitehead","html_url":"https://github.com/BenWhitehead","followers_url":"https://api.github.com/users/BenWhitehead/followers","following_url":"https://api.github.com/users/BenWhitehead/following{/other_user}","gists_url":"https://api.github.com/users/BenWhitehead/gists{/gist_id}","starred_url":"https://api.github.com/users/BenWhitehead/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenWhitehead/subscriptions","organizations_url":"https://api.github.com/users/BenWhitehead/orgs","repos_url":"https://api.github.com/users/BenWhitehead/repos","events_url":"https://api.github.com/users/BenWhitehead/events{/privacy}","received_events_url":"https://api.github.com/users/BenWhitehead/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/dcos/dcos-docs/pulls/431/commits","review_comments_url":"https://api.github.com/repos/dcos/dcos-docs/pulls/431/comments","review_comment_url":"https://api.github.com/repos/dcos/dcos-docs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dcos/dcos-docs/issues/431/comments","statuses_url":"https://api.github.com/repos/dcos/dcos-docs/statuses/caf12e879e3a96af468d28ee8eac23dbe6f8ffb4","head":{"label":"dcos:create-universe-package","ref":"create-universe-package","sha":"caf12e879e3a96af468d28ee8eac23dbe6f8ffb4","user":{"login":"dcos","id":17648048,"avatar_url":"https://avatars.githubusercontent.com/u/17648048?v=3","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"repo":{"id":53887483,"name":"dcos-docs","full_name":"dcos/dcos-docs","owner":{"login":"dcos","id":17648048,"avatar_url":"https://avatars.githubusercontent.com/u/17648048?v=3","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dcos/dcos-docs","description":"Documentation for Datacenter Operating System (DC/OS)","fork":false,"url":"https://api.github.com/repos/dcos/dcos-docs","forks_url":"https://api.github.com/repos/dcos/dcos-docs/forks","keys_url":"https://api.github.com/repos/dcos/dcos-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dcos/dcos-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dcos/dcos-docs/teams","hooks_url":"https://api.github.com/repos/dcos/dcos-docs/hooks","issue_events_url":"https://api.github.com/repos/dcos/dcos-docs/issues/events{/number}","events_url":"https://api.github.com/repos/dcos/dcos-docs/events","assignees_url":"https://api.github.com/repos/dcos/dcos-docs/assignees{/user}","branches_url":"https://api.github.com/repos/dcos/dcos-docs/branches{/branch}","tags_url":"https://api.github.com/repos/dcos/dcos-docs/tags","blobs_url":"https://api.github.com/repos/dcos/dcos-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dcos/dcos-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dcos/dcos-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/dcos/dcos-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dcos/dcos-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/dcos/dcos-docs/languages","stargazers_url":"https://api.github.com/repos/dcos/dcos-docs/stargazers","contributors_url":"https://api.github.com/repos/dcos/dcos-docs/contributors","subscribers_url":"https://api.github.com/repos/dcos/dcos-docs/subscribers","subscription_url":"https://api.github.com/repos/dcos/dcos-docs/subscription","commits_url":"https://api.github.com/repos/dcos/dcos-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/dcos/dcos-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/dcos/dcos-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/dcos/dcos-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/dcos/dcos-docs/contents/{+path}","compare_url":"https://api.github.com/repos/dcos/dcos-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dcos/dcos-docs/merges","archive_url":"https://api.github.com/repos/dcos/dcos-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dcos/dcos-docs/downloads","issues_url":"https://api.github.com/repos/dcos/dcos-docs/issues{/number}","pulls_url":"https://api.github.com/repos/dcos/dcos-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/dcos/dcos-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/dcos/dcos-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dcos/dcos-docs/labels{/name}","releases_url":"https://api.github.com/repos/dcos/dcos-docs/releases{/id}","deployments_url":"https://api.github.com/repos/dcos/dcos-docs/deployments","created_at":"2016-03-14T19:58:33Z","updated_at":"2016-07-12T20:06:52Z","pushed_at":"2016-08-04T17:04:37Z","git_url":"git://github.com/dcos/dcos-docs.git","ssh_url":"git@github.com:dcos/dcos-docs.git","clone_url":"https://github.com/dcos/dcos-docs.git","svn_url":"https://github.com/dcos/dcos-docs","homepage":"http://dcos.io","size":33387,"stargazers_count":56,"watchers_count":56,"language":"Shell","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":44,"mirror_url":null,"open_issues_count":12,"forks":44,"open_issues":12,"watchers":56,"default_branch":"master"}},"base":{"label":"dcos:master","ref":"master","sha":"dcf92e09826a028420dafbe6f335a597352ff1ca","user":{"login":"dcos","id":17648048,"avatar_url":"https://avatars.githubusercontent.com/u/17648048?v=3","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"repo":{"id":53887483,"name":"dcos-docs","full_name":"dcos/dcos-docs","owner":{"login":"dcos","id":17648048,"avatar_url":"https://avatars.githubusercontent.com/u/17648048?v=3","gravatar_id":"","url":"https://api.github.com/users/dcos","html_url":"https://github.com/dcos","followers_url":"https://api.github.com/users/dcos/followers","following_url":"https://api.github.com/users/dcos/following{/other_user}","gists_url":"https://api.github.com/users/dcos/gists{/gist_id}","starred_url":"https://api.github.com/users/dcos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dcos/subscriptions","organizations_url":"https://api.github.com/users/dcos/orgs","repos_url":"https://api.github.com/users/dcos/repos","events_url":"https://api.github.com/users/dcos/events{/privacy}","received_events_url":"https://api.github.com/users/dcos/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dcos/dcos-docs","description":"Documentation for Datacenter Operating System (DC/OS)","fork":false,"url":"https://api.github.com/repos/dcos/dcos-docs","forks_url":"https://api.github.com/repos/dcos/dcos-docs/forks","keys_url":"https://api.github.com/repos/dcos/dcos-docs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dcos/dcos-docs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dcos/dcos-docs/teams","hooks_url":"https://api.github.com/repos/dcos/dcos-docs/hooks","issue_events_url":"https://api.github.com/repos/dcos/dcos-docs/issues/events{/number}","events_url":"https://api.github.com/repos/dcos/dcos-docs/events","assignees_url":"https://api.github.com/repos/dcos/dcos-docs/assignees{/user}","branches_url":"https://api.github.com/repos/dcos/dcos-docs/branches{/branch}","tags_url":"https://api.github.com/repos/dcos/dcos-docs/tags","blobs_url":"https://api.github.com/repos/dcos/dcos-docs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dcos/dcos-docs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dcos/dcos-docs/git/refs{/sha}","trees_url":"https://api.github.com/repos/dcos/dcos-docs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dcos/dcos-docs/statuses/{sha}","languages_url":"https://api.github.com/repos/dcos/dcos-docs/languages","stargazers_url":"https://api.github.com/repos/dcos/dcos-docs/stargazers","contributors_url":"https://api.github.com/repos/dcos/dcos-docs/contributors","subscribers_url":"https://api.github.com/repos/dcos/dcos-docs/subscribers","subscription_url":"https://api.github.com/repos/dcos/dcos-docs/subscription","commits_url":"https://api.github.com/repos/dcos/dcos-docs/commits{/sha}","git_commits_url":"https://api.github.com/repos/dcos/dcos-docs/git/commits{/sha}","comments_url":"https://api.github.com/repos/dcos/dcos-docs/comments{/number}","issue_comment_url":"https://api.github.com/repos/dcos/dcos-docs/issues/comments{/number}","contents_url":"https://api.github.com/repos/dcos/dcos-docs/contents/{+path}","compare_url":"https://api.github.com/repos/dcos/dcos-docs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dcos/dcos-docs/merges","archive_url":"https://api.github.com/repos/dcos/dcos-docs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dcos/dcos-docs/downloads","issues_url":"https://api.github.com/repos/dcos/dcos-docs/issues{/number}","pulls_url":"https://api.github.com/repos/dcos/dcos-docs/pulls{/number}","milestones_url":"https://api.github.com/repos/dcos/dcos-docs/milestones{/number}","notifications_url":"https://api.github.com/repos/dcos/dcos-docs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dcos/dcos-docs/labels{/name}","releases_url":"https://api.github.com/repos/dcos/dcos-docs/releases{/id}","deployments_url":"https://api.github.com/repos/dcos/dcos-docs/deployments","created_at":"2016-03-14T19:58:33Z","updated_at":"2016-07-12T20:06:52Z","pushed_at":"2016-08-04T17:04:37Z","git_url":"git://github.com/dcos/dcos-docs.git","ssh_url":"git@github.com:dcos/dcos-docs.git","clone_url":"https://github.com/dcos/dcos-docs.git","svn_url":"https://github.com/dcos/dcos-docs","homepage":"http://dcos.io","size":33387,"stargazers_count":56,"watchers_count":56,"language":"Shell","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":44,"mirror_url":null,"open_issues_count":12,"forks":44,"open_issues":12,"watchers":56,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/431"},"html":{"href":"https://github.com/dcos/dcos-docs/pull/431"},"issue":{"href":"https://api.github.com/repos/dcos/dcos-docs/issues/431"},"comments":{"href":"https://api.github.com/repos/dcos/dcos-docs/issues/431/comments"},"review_comments":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/431/comments"},"review_comment":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dcos/dcos-docs/pulls/431/commits"},"statuses":{"href":"https://api.github.com/repos/dcos/dcos-docs/statuses/caf12e879e3a96af468d28ee8eac23dbe6f8ffb4"}}}}
{"actor":{"display_login":"BenWhitehead"}}