Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@vkontakte/vk-miniapps-deploy

Package Overview
Dependencies
Maintainers
3
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vkontakte/vk-miniapps-deploy

Deploy to VK Mini Apps hosting with one simple command

  • 0.1.8
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
3
Created
Source

VK Mini Apps Deploy npm

Deploy straight to VK Mini Apps hosting with one simple command.

Usage

# install it from npm and symlink it into your PATH
npm install @vkontakte/vk-miniapps-deploy -g

# now run it!
vk-miniapps-deploy

You can also use npm run to package it with your app without installing it globally.

First add this to your scripts section of package.json:

  "scripts": {
    "deploy": "vk-miniapps-deploy",
    "clean-source": "rimraf README.md src webroot package.json"
  },

And then install vk-miniapps-deploy as a devDependency:

npm install @vkontakte/vk-miniapps-deploy --save-dev

And now you can run npm run deploy to run the vk-miniapps-deploy installed in the local node_modules folder (even if you have never done npm install vk-miniapps-deploy -g).

Options

To configure vk-miniapps-deploy all you need to do is specify a couple of things in your vk-hosting-config.json

{
  "static_path": "build",
  "app_id": "...",
  "endpoints": {
    "mobile": "index.html",
    "mvk": "index.html",
    "web": "index.html"
  }
}

How to use:

  • Make sure that in package.json the key value «homepage» is «./»
  • Copy the example config to the root folder of your application vk-hosting-config.json.example and remove the suffix «.example»
  • Run yarn deploy

For your CI, you can use

$ env MINI_APPS_ACCESS_TOKEN=<token> yarn deploy

with user token retrieved from vk-miniapps-deploy OR service token of deployable application

There are two values to specify MINI_APPS_ENVIRONMENT: production or dev. All production builds will be also deployed on dev environment.

If you grep URL paths, you can use environment variable CI_URLS = true.

Troubleshooting:

If you get an error User authorization failed: invalid session, try this comand:

rm ~/.config/configstore/@vkontakte/vk-miniapps-deploy.json

FAQs

Package last updated on 04 Jun 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc