Skip to main content
Version: Next

createFetchRailsAction()

Home > @backstage/plugin-scaffolder-backend-module-rails > createFetchRailsAction

Creates the fetch:rails Scaffolder action.

Signature:

function createFetchRailsAction(options: {
reader: UrlReaderService;
integrations: ScmIntegrations;
containerRunner?: ContainerRunner;
allowedImageNames?: string[];
}): import("@backstage/plugin-scaffolder-node").TemplateAction<{
url: string;
values: {
railsArguments?: {
template?: string | undefined;
database?: "sqlite3" | "mysql" | "postgresql" | "oracle" | "sqlserver" | "jdbcmysql" | "jdbcsqlite3" | "jdbcpostgresql" | "jdbc" | undefined;
api?: boolean | undefined;
force?: boolean | undefined;
minimal?: boolean | undefined;
railsVersion?: "edge" | "master" | "dev" | "fromImage" | undefined;
skipActionCable?: boolean | undefined;
skipActionMailbox?: boolean | undefined;
skipActionMailer?: boolean | undefined;
skipActionText?: boolean | undefined;
skipActiveStorage?: boolean | undefined;
skipBundle?: boolean | undefined;
skipTest?: boolean | undefined;
skipWebpackInstall?: boolean | undefined;
skipActiveRecord?: boolean | undefined;
webpacker?: "react" | "angular" | "vue" | "elm" | "stimulus" | undefined;
} | undefined;
};
targetPath?: string | undefined;
imageName?: string | undefined;
}, {
[x: string]: any;
}, "v2">;

Parameters

Parameter

Type

Description

options

{ reader: UrlReaderService; integrations: ScmIntegrations; containerRunner?: ContainerRunner; allowedImageNames?: string[]; }

Configuration of the templater.

**Returns:**

import("@backstage/plugin-scaffolder-node").TemplateAction<{ url: string; values: { railsArguments?: { template?: string | undefined; database?: "sqlite3" | "mysql" | "postgresql" | "oracle" | "sqlserver" | "jdbcmysql" | "jdbcsqlite3" | "jdbcpostgresql" | "jdbc" | undefined; api?: boolean | undefined; force?: boolean | undefined; minimal?: boolean | undefined; railsVersion?: "edge" | "master" | "dev" | "fromImage" | undefined; skipActionCable?: boolean | undefined; skipActionMailbox?: boolean | undefined; skipActionMailer?: boolean | undefined; skipActionText?: boolean | undefined; skipActiveStorage?: boolean | undefined; skipBundle?: boolean | undefined; skipTest?: boolean | undefined; skipWebpackInstall?: boolean | undefined; skipActiveRecord?: boolean | undefined; webpacker?: "react" | "angular" | "vue" | "elm" | "stimulus" | undefined; } | undefined; }; targetPath?: string | undefined; imageName?: string | undefined; }, { [x: string]: any; }, "v2">

Remarks

See https://guides.rubyonrails.org/rails_application_templates.html and https://backstage.io/docs/features/software-templates/writing-custom-actions.