I’m a student at WGU and I recently finished the new Software 1 project. It was a desktop app using JavaFX to mock an ERP for a business that sells products that have parts inside of them. It’s a great proof-of-concept app, but there’s a lot lacking from the initial requirements document. There’s no way any company would look at what I built for the Software I class and say “Hey, I can use that right now!” So I decided to fix the issues that I saw with the architecture to make it more appealing to enterprises that might want a basic ERP for order transacting. To do this I’m going to move this JavaFX desktop app to the web with ASP.NET, Microsft SQL Server Express, and Docker. Why ASP.NET you ask? I decided that ASP.NET (specifically ASP.NET Core) would be good to learn because I already work with C# in my day job, I’m already pretty comfortable with other frameworks like Laravel, Ruby-on-Rails, and Phoenix, and ASP.NET is well used in the enterprise. I’ve also wanted to use Docker in-depth for awhile, and Microsoft has first-class support for Docker in ASP.NET core.
To get started I cloned my school repo and checked out a new branch to stash my old work, then I cleared out the master branch:
C:\Users\Jonathan\Documents\Projects λ git clone email@example.com:colonelpopcorn/C482.git C:\Users\Jonathan\Documents\Projects λ cd .\C482\ C:\Users\Jonathan\Documents\Projects\C482 [master ≡] λ git checkout -b submission-final Switched to a new branch 'submission-final' C:\Users\Jonathan\Documents\Projects\C482 [submission-final] λ git push -u origin submission-final Total 0 (delta 0), reused 0 (delta 0) To github.com:colonelpopcorn/C482.git * [new branch] submission-final -> submission-final Branch submission-final set up to track remote branch submission-final from origin. C:\Users\Jonathan\Documents\Projects\C482 [submission-final ≡] λ git checkout master Switched to branch 'master' Your branch is up-to-date with 'origin/master'. C:\Users\Jonathan\Documents\Projects\C482 [master ≡] λ git rm * C:\Users\Jonathan\Documents\Projects\C482 [master ≡ +0 ~0 -19 ~] λ git commit -m "Cleaning out directory" C:\Users\Jonathan\Documents\Projects\C482 [master ↑1] λ git push
All right, now we can get started with visual studio. There’s a lot of great scaffolding features in visual studio 2017. We can use templates for ASP.NET core, Docker, Unit tests, and more. I used a web app scaffold for ASP.NET core with Docker support.
As part of my enhancement plan, I decided roles would probably be necessary. I made sure that user accounts could be made by hitting change authentication and selecting Individual User Accounts.
Depending on your use case you may want to use work, school, or even LDAP authentication. I wanted to use user accounts to provide more granular control over the app, so I chose individual user accounts. This allows to use email to register users or OAuth providers like Google, Facebook, or Twitter. At this point I went ahead and commited the boilerplate to the git repo. Running the application should work now, provided you’ve got Docker set up correctly in Windows. If all goes well hitting the play button in Visual Studio should pull up Chrome or another browser with the page below.
So now we have some basic boilerplate for our web application. Nice. In the next post, we’ll add a CI workflow with Appveyor and start building out our UI.